diff --git a/core/src/com/trs/game/model/Monster.java b/core/src/com/trs/game/model/Monster.java index af9a2db..c272082 100644 --- a/core/src/com/trs/game/model/Monster.java +++ b/core/src/com/trs/game/model/Monster.java @@ -19,6 +19,8 @@ public class Monster { } public void move(){ + checkTarget(); + this.xPos += this.movementX; this.yPos += this.movementY; } @@ -30,7 +32,8 @@ public class Monster { } private void generateNewTarget(){ - // TODO: generate new target coordinates + xPosTarget = (int) (Math.random() * 1400) + 100; + yPosTarget = (int) (Math.random() * 700) + 100; calculateMovement(); }