Skip to content

Commit

Permalink
Removed extra code from EngineerCombatTask.
Browse files Browse the repository at this point in the history
  • Loading branch information
praneetdhoolia committed Sep 10, 2023
1 parent c73b365 commit 32725aa
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ public class EngineerCombatTask extends DefaultTask implements PriorityTask {
private static final short TARGET = PhysicsLayer.NPC; // The type of targets that the Engineer will detect.

// Animation event names for the Engineer's state machine.
private static final String STOW = "";
private static final String DEPLOY = "";
private static final String FIRING = "firingSingleStart";
private static final String IDLE_LEFT = "idleLeft";
private static final String IDLE_RIGHT = "idleRight";
Expand Down Expand Up @@ -96,7 +94,7 @@ public void update() {
* Engineer state machine
*/
public void updateEngineerState() {
// configure tower state depending on target visibility
// configure engineer state depending on target visibility
switch (engineerState) {
case IDLE_LEFT -> {
// targets detected in idle mode - start deployment
Expand All @@ -113,15 +111,6 @@ public void updateEngineerState() {
combatState();
}
}
case DEPLOY -> {
// currently deploying,
if (isTargetVisible()) {
combatState();
} else {
owner.getEntity().getEvents().trigger(STOW);
engineerState = STATE.STOW;
}
}
case FIRING -> {
// targets gone - stop firing
if (!isTargetVisible()) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
package com.csse3200.game.components.tasks;public class EngineerCombatTaskTest {
package com.csse3200.game.components.tasks;
public class EngineerCombatTaskTest {
}

0 comments on commit 32725aa

Please sign in to comment.