From 9e8bffd70d2366de3e066ee38f3ff729850f9805 Mon Sep 17 00:00:00 2001 From: fdai2751 Date: Wed, 31 Jan 2024 22:01:42 +0100 Subject: [PATCH] refractoring: new fonction Update() time variable in 5 step --- src/main/java/pacmanGame/GameManager.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/java/pacmanGame/GameManager.java b/src/main/java/pacmanGame/GameManager.java index 5ac9fcb..117c264 100644 --- a/src/main/java/pacmanGame/GameManager.java +++ b/src/main/java/pacmanGame/GameManager.java @@ -23,6 +23,9 @@ public class GameManager { } public void Update() { visualizer.Update(); + if(time%5 == 0) { + player.Move(); + } time++; }