added init for mdga with all states and messages

This commit is contained in:
Cedric Beck
2024-11-12 17:26:10 +01:00
parent ef16a3f92b
commit a684405891
238 changed files with 1596 additions and 44560 deletions

View File

@@ -0,0 +1,37 @@
package pp.mdga.game;
public class Piece {
private ShieldState shield;
private PieceState state;
private Color color;
public Piece(Color color, PieceState state) {
this.color = color;
this.state = state;
shield = ShieldState.NONE;
}
public void setShield(ShieldState shield) {
this.shield = shield;
}
public ShieldState getShield() {
return shield;
}
public void setState(PieceState state) {
this.state = state;
}
public PieceState getState() {
return state;
}
public boolean isShielded() {
return shield == ShieldState.ACTIVE;
}
public boolean isSuppressed() {
return shield == ShieldState.SUPPRESSED;
}
}