Explorar o código

added 'resetClock' event message

Darren Ranalli %!s(int64=24) %!d(string=hai) anos
pai
achega
2d76f5175a
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      direct/src/task/Task.py

+ 3 - 0
direct/src/task/Task.py

@@ -482,8 +482,11 @@ class TaskManager:
         # Set the clock to have last frame's time in case we were
         # Paused at the prompt for a long time
         t = globalClock.getFrameTime()
+        timeDelta = t - globalClock.getRealTime()
         globalClock.setRealTime(t)
 
+        messenger.send("resetClock", [timeDelta])
+
         if self.resumeFunc != None:
             self.resumeFunc()