diff --git a/src/main/java/eu/mhsl/minenet/minigames/instance/game/stateless/types/towerdefense/Towerdefense.java b/src/main/java/eu/mhsl/minenet/minigames/instance/game/stateless/types/towerdefense/Towerdefense.java index 6fec923..f736463 100644 --- a/src/main/java/eu/mhsl/minenet/minigames/instance/game/stateless/types/towerdefense/Towerdefense.java +++ b/src/main/java/eu/mhsl/minenet/minigames/instance/game/stateless/types/towerdefense/Towerdefense.java @@ -44,7 +44,7 @@ public class Towerdefense extends StatelessGame { long rightLeftDifference = previousDirections.stream().filter(integer -> integer == 0).count() - previousDirections.stream().filter(integer -> integer == 2).count(); if(rightLeftDifference >= 2 || direction == 2) origin = 1; if(rightLeftDifference <= -2 || direction == 0) bound = 2; - direction = random.nextInt(origin, bound); + direction = this.random.nextInt(origin, bound); previousDirections.add(direction); } this.addMazePosition(position, Block.WHITE_WOOL);