summaryrefslogtreecommitdiff
path: root/src/client.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-12-23 00:27:06 +0300
committerAndrei Karas <akaras@inbox.ru>2011-12-23 00:27:06 +0300
commita901facc32f489dbce6f9193f618d9d46a91f32c (patch)
treefcdb928294e8839eae1172873f63c3c0493fb968 /src/client.cpp
parent2ad5d25e30d7247d67a4784a6cb9e96245643960 (diff)
downloadmanaverse-a901facc32f489dbce6f9193f618d9d46a91f32c.tar.gz
manaverse-a901facc32f489dbce6f9193f618d9d46a91f32c.tar.bz2
manaverse-a901facc32f489dbce6f9193f618d9d46a91f32c.tar.xz
manaverse-a901facc32f489dbce6f9193f618d9d46a91f32c.zip
Probably fix auto adjusting perfomance after going from sleep mode.
Diffstat (limited to 'src/client.cpp')
-rw-r--r--src/client.cpp8
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();