From 1b864413966ca75990611a063e36a65372c00cf6 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 23 Mar 2013 15:26:17 +0300 Subject: Improve speed in main cycle. --- src/client.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/client.cpp b/src/client.cpp index dc4f118a8..8f64b6b1e 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -995,21 +995,21 @@ int Client::gameExec() BLOCK_END("Client::gameExec 3") BLOCK_START("Client::gameExec 4") + if (gui) + gui->logic(); int k = 0; while (lastTickTime != tick_time && k < 40) { - if (gui) - gui->logic(); if (mGame) mGame->logic(); else if (gui) gui->handleInput(); - sound.logic(); - ++lastTickTime; k ++; } + sound.logic(); + logic_count += k; if (gui) gui->slowLogic(); -- cgit v1.2.3-70-g09d2