package domain; import java.util.ArrayList; import java.util.Collection; import java.util.Collections; public class Game { private ArrayList currentPlayers; private int turnPlayer; private Dice dice; public Game(){ currentPlayers = new ArrayList(); turnPlayer = 0; dice = new Dice(6); } public void nextTurn(){ Collections.rotate(currentPlayers, -1); } public Player getCurrentPlayer(){ return currentPlayers.getFirst(); } public int rollDice(){ return dice.roll(); } public void addPlayer(Player playerToAdd){ currentPlayers.add(playerToAdd); } public ArrayList getPlayers(){ return currentPlayers; } }