Added missing override annotations
This commit is contained in:
parent
b02a5756a5
commit
f8eb39d2fb
@ -7,9 +7,11 @@ public class Box implements Pickable, Destroyable {
|
||||
public Box() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void destroy() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void pick() {
|
||||
}
|
||||
|
||||
|
@ -10,6 +10,7 @@ public class Field extends cicaprojekt.Tile {
|
||||
return boxStack.isEmpty();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onEntry(PlayerBase playerBase) {
|
||||
super.onEntry(playerBase);
|
||||
if (boxStack.size() > 0)
|
||||
@ -19,5 +20,6 @@ public class Field extends cicaprojekt.Tile {
|
||||
playerBase.pickZPM(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onExit(PlayerBase playerBase) {}
|
||||
}
|
||||
|
@ -11,11 +11,13 @@ public class Gap extends cicaprojekt.Tile {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onEntry(PlayerBase playerBase) {
|
||||
super.onEntry(playerBase);
|
||||
playerBase.destroy();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onExit(PlayerBase playerBase) throws IllegalStateException {
|
||||
throw new IllegalStateException("Hiba! A szakadékból nem jut ki semmi!");
|
||||
}
|
||||
|
@ -12,11 +12,13 @@ public class Gate extends Tile {
|
||||
if (this.open) adjacentTile.get(direction).spawnStargate(stargate, direction);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onEntry(PlayerBase playerBase) {
|
||||
super.onEntry(playerBase);
|
||||
if (open) playerBase.setCurrentTile(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onExit(PlayerBase playerBase) throws IllegalStateException {
|
||||
if (!open) {
|
||||
throw new IllegalStateException("Hiba! Te hogy kerültél a csukott ajtóba?");
|
||||
|
@ -18,6 +18,7 @@ public class PlayerBase implements Destroyable {
|
||||
return String.format("%s: %s", name, currentTile);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void destroy() {
|
||||
destroyed = true;
|
||||
Game.instance.playerBaseDestroyed(this);
|
||||
|
@ -30,12 +30,14 @@ public class Wall extends Tile {
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onEntry(PlayerBase playerBase) {
|
||||
super.onEntry(playerBase);
|
||||
if (sg != null)
|
||||
sg.teleport(playerBase);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onExit(PlayerBase playerBase) throws IllegalStateException {
|
||||
if(sg != null) return;
|
||||
throw new IllegalStateException("Hiba! Te hogy kerültél a falba?");
|
||||
|
@ -1,6 +1,7 @@
|
||||
package cicaprojekt;
|
||||
|
||||
public class ZPM implements Pickable {
|
||||
@Override
|
||||
public void pick() {
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user