deleted unwanted code (next Color)
This commit is contained in:
@@ -85,7 +85,7 @@ public Game() {
|
|||||||
gameStatistics = new Statistic();
|
gameStatistics = new Statistic();
|
||||||
initializeDrawPile();
|
initializeDrawPile();
|
||||||
board = new Board();
|
board = new Board();
|
||||||
die = new Die();
|
die = new Die(2,1,6,2,1,3);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -36,12 +36,9 @@ public void enter() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void setActivePlayer(Color activePlayer) {
|
private void setActivePlayer(Color activePlayer) {
|
||||||
if (!logic.getGame().getPlayerByColor(activePlayer.next(logic.getGame())).isFinished()) {
|
Color newColor = activePlayer.next(logic.getGame());
|
||||||
logic.getGame().setActiveColor(logic.getGame().getActiveColor().next(logic.getGame()));
|
logic.getGame().setActiveColor(newColor);
|
||||||
logic.getServerSender().broadcast(new ActivePlayerMessage(activePlayer.next(logic.getGame())));
|
logic.getServerSender().broadcast(new ActivePlayerMessage(newColor));
|
||||||
} else {
|
|
||||||
throw new RuntimeException("handle player finished is not yet implemented"); //TODO
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Reference in New Issue
Block a user