diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-12-23 00:27:06 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-12-23 00:27:06 +0300 |
commit | a901facc32f489dbce6f9193f618d9d46a91f32c (patch) | |
tree | fcdb928294e8839eae1172873f63c3c0493fb968 /src/client.cpp | |
parent | 2ad5d25e30d7247d67a4784a6cb9e96245643960 (diff) | |
download | mv-a901facc32f489dbce6f9193f618d9d46a91f32c.tar.gz mv-a901facc32f489dbce6f9193f618d9d46a91f32c.tar.bz2 mv-a901facc32f489dbce6f9193f618d9d46a91f32c.tar.xz mv-a901facc32f489dbce6f9193f618d9d46a91f32c.zip |
Probably fix auto adjusting perfomance after going from sleep mode.
Diffstat (limited to 'src/client.cpp')
-rw-r--r-- | src/client.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/client.cpp b/src/client.cpp index d2b26f662..b5cbffd40 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -2238,6 +2238,14 @@ void Client::setFramerate(int fpsLimit) SDL_setFramerate(&instance()->mFpsManager, fpsLimit); } +int Client::getFramerate() +{ + if (!instance()->mLimitFps) + return 0; + + return SDL_getFramerate(&instance()->mFpsManager); +} + void Client::closeDialogs() { Net::getNpcHandler()->clearDialogs(); |