Skip to content
Snippets Groups Projects
Commit 488ddf3f authored by Fabian Heinrich's avatar Fabian Heinrich
Browse files

Correct time delta

parent 984851bc
No related branches found
No related tags found
1 merge request!55Resolve "Second window"
Pipeline #46096 passed
......@@ -250,7 +250,7 @@ class PyGameGUI:
current_player_name,
ActionType.MOVEMENT,
move_vec,
duration=1 / self.time_delta, # TODO use fps of previous clock step
duration=self.time_delta, # TODO use fps of previous clock step
)
self.send_action(action)
......@@ -1031,8 +1031,8 @@ class PyGameGUI:
self.running = True
while self.running:
try:
self.time_delta = clock.tick(self.FPS) / 1000.0
self.time_delta = clock.tick(self.FPS) / 1000
print(self.time_delta)
# print(clock.get_time())
for event in pygame.event.get():
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment