Version 1.0 #40

Merged
j23f0779 merged 947 commits from development2 into main 2024-12-13 10:26:49 +01:00
Showing only changes of commit bf3d800c10 - Show all commits

View File

@@ -41,8 +41,14 @@ public ServerCardVisitor(ServerGameLogic logic) {
*/
@Override
public void visit(TurboCard card) {
for (Piece piece : this.logic.getGame().getPlayerByColor(this.logic.getGame().getActiveColor()).getPieces()) {
if (piece.getState() == PieceState.ACTIVE) {
if (!this.cards.contains(card)) {
this.cards.add(card);
}
}
}
}
/**
* This method will be used to visit the given card parameter.