diff options
Diffstat (limited to 'src')
4 files changed, 8 insertions, 6 deletions
diff --git a/src/main/java/org/luxons/sevenwonders/game/effects/BonusPerBoardElement.java b/src/main/java/org/luxons/sevenwonders/game/effects/BonusPerBoardElement.java index 51da55bb..f876328c 100644 --- a/src/main/java/org/luxons/sevenwonders/game/effects/BonusPerBoardElement.java +++ b/src/main/java/org/luxons/sevenwonders/game/effects/BonusPerBoardElement.java @@ -6,7 +6,7 @@ import org.luxons.sevenwonders.game.boards.Board; import org.luxons.sevenwonders.game.RelativePlayerPosition; import org.luxons.sevenwonders.game.cards.Color; -public class BonusPerBoardElement extends Effect { +public class BonusPerBoardElement implements Effect { private List<RelativePlayerPosition> boards; diff --git a/src/main/java/org/luxons/sevenwonders/game/effects/Effect.java b/src/main/java/org/luxons/sevenwonders/game/effects/Effect.java index 86a6ae8c..b9634553 100644 --- a/src/main/java/org/luxons/sevenwonders/game/effects/Effect.java +++ b/src/main/java/org/luxons/sevenwonders/game/effects/Effect.java @@ -2,9 +2,9 @@ package org.luxons.sevenwonders.game.effects; import org.luxons.sevenwonders.game.boards.Board; -public abstract class Effect { +public interface Effect { - public abstract void apply(Board board, Board leftNeighbourBoard, Board rightNeighbourBoard); + void apply(Board board, Board leftNeighbourBoard, Board rightNeighbourBoard); - public abstract int computePoints(Board board, Board leftNeighbourBoard, Board rightNeighbourBoard); + int computePoints(Board board, Board leftNeighbourBoard, Board rightNeighbourBoard); } diff --git a/src/main/java/org/luxons/sevenwonders/game/effects/EndGameEffect.java b/src/main/java/org/luxons/sevenwonders/game/effects/EndGameEffect.java index e7a08e5c..ca8a1948 100644 --- a/src/main/java/org/luxons/sevenwonders/game/effects/EndGameEffect.java +++ b/src/main/java/org/luxons/sevenwonders/game/effects/EndGameEffect.java @@ -2,8 +2,9 @@ package org.luxons.sevenwonders.game.effects; import org.luxons.sevenwonders.game.boards.Board; -public abstract class EndGameEffect extends Effect { +public abstract class EndGameEffect implements Effect { + @Override public void apply(Board board, Board leftNeighbourBoard, Board rightNeighbourBoard) { } } diff --git a/src/main/java/org/luxons/sevenwonders/game/effects/InstantEffect.java b/src/main/java/org/luxons/sevenwonders/game/effects/InstantEffect.java index 9f2e09ff..c3e5455e 100644 --- a/src/main/java/org/luxons/sevenwonders/game/effects/InstantEffect.java +++ b/src/main/java/org/luxons/sevenwonders/game/effects/InstantEffect.java @@ -2,8 +2,9 @@ package org.luxons.sevenwonders.game.effects; import org.luxons.sevenwonders.game.boards.Board; -public abstract class InstantEffect extends Effect { +public abstract class InstantEffect implements Effect { + @Override public int computePoints(Board board, Board leftNeighbourBoard, Board rightNeighbourBoard) { return 0; } |