From cbd196532f6cc2c899e9ca0c3ad81ccb6e5e1a34 Mon Sep 17 00:00:00 2001 From: ericnerdo Date: Sun, 24 Apr 2016 22:28:09 +0200 Subject: [PATCH] Gap - finished --- cicaprojekt/Gap.java | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/cicaprojekt/Gap.java b/cicaprojekt/Gap.java index fb1d807..a07d80a 100644 --- a/cicaprojekt/Gap.java +++ b/cicaprojekt/Gap.java @@ -1,16 +1,26 @@ package cicaprojekt; -public class Gap extends Tile +public class Gap extends cicaprojekt.Tile { + public Gap(){ + super(); + } + @Override - public void spawnStargate(Stargate stargate, Direction direction) { + public void spawnStargate(cicaprojekt.Stargate stargate, Direction direction) { adjacentTile.get(direction).spawnStargate(stargate, direction); } - public void onEntry() { - this.removeItemFromTile().destroy(); + public void onEntry(PlayerBase playerBase) { + playerBase.destroy(); } - public void onExit() { + public void onExit(PlayerBase playerBase) throws IllegalStateException { + throw new IllegalStateException("Hiba! A szakadékból nem jut ki semmi!"); + } + + @Override + public void putABox(Box box) { + box.destroy(); } }