Skip to content

Commit

Permalink
Made inner class static
Browse files Browse the repository at this point in the history
  • Loading branch information
bagarozzi committed Jul 8, 2024
1 parent 350e006 commit 67b2fb4
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import java.util.Stack;
import java.util.List;

import it.unibo.bombardero.bomb.api.BombFactory;
import it.unibo.bombardero.character.Character;
import it.unibo.bombardero.core.api.Controller;
import it.unibo.bombardero.core.api.GameManager;
Expand Down Expand Up @@ -53,7 +54,7 @@ public void updateGame(final long elapsed, final Controller controller) {

@Override
public void spawnDummy() {
addEnemy(new Dummy(DUMMY_GUIDE_SPAWNPOINT));
addEnemy(new BombarderoGuideManager.Dummy(DUMMY_GUIDE_SPAWNPOINT, getBombFactory()));
}

private void initialiseProcedures() {
Expand Down Expand Up @@ -88,14 +89,14 @@ private void initialiseProcedures() {
* It's sole purporse is to be the target of the player during the guide.
* @author Federico Bagattoni
*/
private final class Dummy extends Character {
private static class Dummy extends Character {

/**
* Creates a new dummy at the passed coordinate.
* @param coord where to spawn the dummy
*/
Dummy(final GenPair<Float, Float> coord) {
super(coord, BombarderoGuideManager.this.getBombFactory());
Dummy(final GenPair<Float, Float> coord, final BombFactory bombFactory) {
super(coord, bombFactory);
}

@Override
Expand Down

0 comments on commit 67b2fb4

Please sign in to comment.