From 6b11456b7a862ac9792969f7c570e145b5e0415c Mon Sep 17 00:00:00 2001 From: ericnerdo Date: Sun, 24 Apr 2016 18:27:36 +0200 Subject: [PATCH] Abstract class finished Method-calling texts were removed and methods were implemented. --- cicaprojekt/Tile.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cicaprojekt/Tile.java b/cicaprojekt/Tile.java index 701a630..05732de 100644 --- a/cicaprojekt/Tile.java +++ b/cicaprojekt/Tile.java @@ -23,6 +23,7 @@ public abstract class Tile { } public void setAdajacentTile(Tile newTile, Direction direction) { + adjacentTile.put(direction, newTile); } public abstract void spawnStargate(Stargate stargate, Direction direction); @@ -33,10 +34,11 @@ public abstract class Tile { public Pickable removeItemFromTile() { Pickable item = itemOnTile; + itemOnTile = null; return item; } public void setItemOnTile(Pickable item) { - itemOnTile = item; + itemOnTile = item; } }