Quantcast
Channel: RaGEZONE - MMO Development Forums
Viewing all articles
Browse latest Browse all 14533

[Release] FPS Limiter By Command [1.5]

$
0
0
Hello this is a release for FPS Limiter by a command: /fps <number>


ZChat_Cmds.cpp (.../Stable/Gunz/ZChat_Cmds.cpp) [Line 79]
Code:

void ChatCmd_FPS(const char* line, const int argc, char **const argv);
ZChat_Cmds.cpp (.../Stable/Gunz/ZChat_Cmds.cpp) [Line 205]
Code:

        _CC_AC("fps",                                &ChatCmd_FPS,                                        CCF_ALL, ARGVNoMin, 1 , true,"/fps <number>", "");
ZChat_Cmds.cpp (.../Stable/Gunz/ZChat_Cmds.cpp) [Line 1545]
Code:

void ChatCmd_FPS(const char* line, const int argc, char **const argv)
{
        if (argc < 2)
        {
                ZChatOutput("Enter a FPS value!", ZChat::CMT_SYSTEM);
                return;
        }

        RSetFrameLimitPerSeceond(atoi(argv[1]));
        ZChatOutput("FPS changed successfully!", ZChat::CMT_SYSTEM);
}

RealSpace2.cpp (.../Stable/RealSpace2/Source/RealSpace2.cpp) [Line 1028]
Search for void RSetFrameLimitPerSeceond(unsigned short nFrameLimit) if you have it then edit it to this.
Code:

void RSetFrameLimitPerSeceond(unsigned short nFrameLimit)
{
        g_nFrameLimitValue = nFrameLimit;
}

if you don't have it then copy the function above, and paste it somewhere with the functions below it.

NOTE: Lines might be different. :O
--------------------------------------
Thanks to qet123 for help. ;)
Like if you use it or if it helps you...

Viewing all articles
Browse latest Browse all 14533

Trending Articles