aboutsummaryrefslogtreecommitdiffstats
path: root/Game/Code/Classes/UTime.pas
diff options
context:
space:
mode:
Diffstat (limited to 'Game/Code/Classes/UTime.pas')
-rw-r--r--Game/Code/Classes/UTime.pas6
1 files changed, 5 insertions, 1 deletions
diff --git a/Game/Code/Classes/UTime.pas b/Game/Code/Classes/UTime.pas
index 87d4f922..d06628cc 100644
--- a/Game/Code/Classes/UTime.pas
+++ b/Game/Code/Classes/UTime.pas
@@ -69,7 +69,11 @@ begin
TimeNew := CurrentSec100OfDay(); // TODO - JB_Linux will prob need looking at
{$ENDIF}
- TimeSkip := (TimeNew-TimeOld)/TimeFreq;
+ if ( TimeNew-TimeOld > 0 ) AND
+ ( TimeFreq > 0 ) THEN
+ begin
+ TimeSkip := (TimeNew-TimeOld)/TimeFreq;
+ end;
end;
procedure CountMidTime;