diff options
author | jbion <joffrey.bion@amadeus.com> | 2016-12-22 22:06:23 +0100 |
---|---|---|
committer | jbion <joffrey.bion@amadeus.com> | 2016-12-22 22:06:23 +0100 |
commit | c371788a9063663bdb8bd0b9346b1381cf9cc6d0 (patch) | |
tree | 671d8b42e1ded2f658bc7d0981012da396f556f4 /src | |
parent | Add CardBack for wonder stages display in the UI (diff) | |
download | seven-wonders-c371788a9063663bdb8bd0b9346b1381cf9cc6d0.tar.gz seven-wonders-c371788a9063663bdb8bd0b9346b1381cf9cc6d0.tar.bz2 seven-wonders-c371788a9063663bdb8bd0b9346b1381cf9cc6d0.zip |
Remove middleman methods in Board
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/org/luxons/sevenwonders/game/api/Table.java | 4 | ||||
-rw-r--r-- | src/main/java/org/luxons/sevenwonders/game/boards/Board.java | 11 |
2 files changed, 2 insertions, 13 deletions
diff --git a/src/main/java/org/luxons/sevenwonders/game/api/Table.java b/src/main/java/org/luxons/sevenwonders/game/api/Table.java index d906a5f1..44c9076f 100644 --- a/src/main/java/org/luxons/sevenwonders/game/api/Table.java +++ b/src/main/java/org/luxons/sevenwonders/game/api/Table.java @@ -55,7 +55,7 @@ public class Table { public void buildWonderStage(int playerIndex, CardBack cardBack) { Board board = boards.get(playerIndex); - board.buildWonderStage(cardBack); + board.getWonder().buildLevel(cardBack); } public void activateCard(int playerIndex, Card card, List<BoughtResources> boughtResources) { @@ -64,7 +64,7 @@ public class Table { public void activateCurrentWonderStage(int playerIndex, List<BoughtResources> boughtResources) { Board board = boards.get(playerIndex); - board.activateCurrentWonderLevel(this, playerIndex, boughtResources); + board.getWonder().activateLastBuiltStage(this, playerIndex, boughtResources); } public void discard(int playerIndex, int goldBonus) { diff --git a/src/main/java/org/luxons/sevenwonders/game/boards/Board.java b/src/main/java/org/luxons/sevenwonders/game/boards/Board.java index 7e310979..f2f39503 100644 --- a/src/main/java/org/luxons/sevenwonders/game/boards/Board.java +++ b/src/main/java/org/luxons/sevenwonders/game/boards/Board.java @@ -5,10 +5,7 @@ import java.util.List; import org.luxons.sevenwonders.game.Player; import org.luxons.sevenwonders.game.Settings; -import org.luxons.sevenwonders.game.api.BoughtResources; -import org.luxons.sevenwonders.game.api.Table; import org.luxons.sevenwonders.game.cards.Card; -import org.luxons.sevenwonders.game.cards.CardBack; import org.luxons.sevenwonders.game.cards.Color; import org.luxons.sevenwonders.game.resources.Production; import org.luxons.sevenwonders.game.wonders.Wonder; @@ -85,14 +82,6 @@ public class Board { this.gold = amount; } - public void buildWonderStage(CardBack cardBack) { - wonder.buildLevel(cardBack); - } - - public void activateCurrentWonderLevel(Table table, int playerIndex, List<BoughtResources> boughtResources) { - wonder.activateLastBuiltStage(table, playerIndex, boughtResources); - } - public int getNbWarSymbols() { return nbWarSymbols; } |