From 70a2179ccea64511497134b8d3c47ed3c1b35d23 Mon Sep 17 00:00:00 2001 From: romanschenk37 <84532681+romanschenk37@users.noreply.github.com> Date: Fri, 25 Mar 2022 21:14:18 +0100 Subject: [PATCH] Code Cleanup --- follower/challenge_points.txt | 4 ++++ src/main/java/ch/zhaw/pm2/racetrack/Game.java | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/follower/challenge_points.txt b/follower/challenge_points.txt index d794046..4d7fec6 100644 --- a/follower/challenge_points.txt +++ b/follower/challenge_points.txt @@ -1,3 +1,7 @@ +(X:28, Y:22) +(X:31, Y:22) +(X:34, Y:22) +(X:37, Y:22) (X:40, Y:22) (X:43, Y:22) (X:46, Y:21) diff --git a/src/main/java/ch/zhaw/pm2/racetrack/Game.java b/src/main/java/ch/zhaw/pm2/racetrack/Game.java index 4203a3e..480e8c5 100644 --- a/src/main/java/ch/zhaw/pm2/racetrack/Game.java +++ b/src/main/java/ch/zhaw/pm2/racetrack/Game.java @@ -94,7 +94,7 @@ public class Game implements GameSpecification { } if(selectedFile != null){ try { - moveStrategy = new PathFollowerMoveStrategy(selectedFile, track.getCarPos(currentCarIndex)); + moveStrategy = new PathFollowerMoveStrategy(selectedFile, track.getCarPos(i)); } catch (FileNotFoundException e) { userInterface.printInformation("There is no Point-List implemented. Choose another Strategy!"); }