hedgewars/uGame.pas
changeset 7414 a9f18c66ce34
parent 7061 4e0fc59ab1ce
child 7418 f611ee4760c0
--- a/hedgewars/uGame.pas	Fri Jul 20 21:15:38 2012 -0400
+++ b/hedgewars/uGame.pas	Fri Jul 20 21:30:53 2012 -0400
@@ -26,7 +26,7 @@
 ////////////////////
     implementation
 ////////////////////
-uses uInputHandler, uTeams, uIO, uAI, uGears, uSound, uMobile, uVisualGears, uTypes, uVariables{$IFDEF SDL13}, uTouch{$ENDIF};
+uses Math, uInputHandler, uTeams, uIO, uAI, uGears, uSound, uMobile, uVisualGears, uTypes, uVariables{$IFDEF SDL13}, uTouch{$ENDIF};
 
 procedure DoGameTick(Lag: LongInt);
 var i: LongInt;
@@ -46,7 +46,7 @@
 
 if (GameType = gmtDemo) then 
     if isSpeed then
-        Lag:= Lag * 10
+        Lag:= Lag * max(min(round(((GameTicks-SpeedStart)+100)/5000),100),5)
     else
         if cOnlyStats then
             Lag:= High(LongInt);