diff --git a/source/core/src/main/com/csse3200/game/components/tasks/RangeBossMovementTask.java b/source/core/src/main/com/csse3200/game/components/tasks/RangeBossTask.java similarity index 95% rename from source/core/src/main/com/csse3200/game/components/tasks/RangeBossMovementTask.java rename to source/core/src/main/com/csse3200/game/components/tasks/RangeBossTask.java index c09e63067..9ff05de28 100644 --- a/source/core/src/main/com/csse3200/game/components/tasks/RangeBossMovementTask.java +++ b/source/core/src/main/com/csse3200/game/components/tasks/RangeBossTask.java @@ -18,8 +18,8 @@ * Wander around by moving a random position within a range of the starting position. Wait a little * bit between movements. Requires an entity with a PhysicsMovementComponent. */ -public class RangeBossMovementTask extends DefaultTask implements PriorityTask { - private static final Logger logger = LoggerFactory.getLogger(RangeBossMovementTask.class); +public class RangeBossTask extends DefaultTask implements PriorityTask { + private static final Logger logger = LoggerFactory.getLogger(RangeBossTask.class); private final float waitTime; private Vector2 currentPos; @@ -33,7 +33,7 @@ public class RangeBossMovementTask extends DefaultTask implements PriorityTask { /** * @param waitTime How long in seconds to wait between wandering. */ - public RangeBossMovementTask(float waitTime) { + public RangeBossTask(float waitTime) { this.waitTime = waitTime; physics = ServiceLocator.getPhysicsService().getPhysics(); diff --git a/source/core/src/main/com/csse3200/game/entities/factories/BossKingFactory.java b/source/core/src/main/com/csse3200/game/entities/factories/BossKingFactory.java index 8451b10cd..a4909f1dc 100644 --- a/source/core/src/main/com/csse3200/game/entities/factories/BossKingFactory.java +++ b/source/core/src/main/com/csse3200/game/entities/factories/BossKingFactory.java @@ -6,7 +6,7 @@ import com.csse3200.game.ai.tasks.AITaskComponent; import com.csse3200.game.components.*; import com.csse3200.game.components.npc.BossAnimationController; -import com.csse3200.game.components.tasks.RangeBossMovementTask; +import com.csse3200.game.components.tasks.RangeBossTask; import com.csse3200.game.entities.Entity; import com.csse3200.game.entities.configs.BossKingConfigs; import com.csse3200.game.entities.configs.NPCConfigs; @@ -29,7 +29,7 @@ public static Entity createBossKing1(Entity target) { BossKingConfigs config = configs.BossKing; Entity bossKing1 = createBaseBoss(target); - AITaskComponent aiTaskComponent1 = new AITaskComponent().addTask(new RangeBossMovementTask(3f)); + AITaskComponent aiTaskComponent1 = new AITaskComponent().addTask(new RangeBossTask(3f)); // Animation section AnimationRenderComponent animator1 = new AnimationRenderComponent( @@ -52,7 +52,7 @@ public static Entity createBossKing2(Entity target) { BossKingConfigs config = configs.BossKing; Entity bossKing2 = createBaseBoss(target); - AITaskComponent aiTaskComponent2 = new AITaskComponent().addTask(new RangeBossMovementTask(2f)); + AITaskComponent aiTaskComponent2 = new AITaskComponent().addTask(new RangeBossTask(2f)); // Animation section AnimationRenderComponent animator2 = new AnimationRenderComponent( diff --git a/source/core/src/test/com/csse3200/game/components/tasks/RangeBossMovementTaskTest.java b/source/core/src/test/com/csse3200/game/components/tasks/RangeBossMovementTaskTest.java index 1e0de6f48..6670d1996 100644 --- a/source/core/src/test/com/csse3200/game/components/tasks/RangeBossMovementTaskTest.java +++ b/source/core/src/test/com/csse3200/game/components/tasks/RangeBossMovementTaskTest.java @@ -32,7 +32,7 @@ void beforeEach() { @Test void shouldTriggerEvent() { - RangeBossMovementTask RBMTask = new RangeBossMovementTask(1f); + RangeBossTask RBMTask = new RangeBossTask(1f); AITaskComponent aiTaskComponent = new AITaskComponent().addTask(RBMTask); Entity entity = new Entity()