|
|
@ -17,10 +17,11 @@ public class Game { |
|
|
|
dice = p.rollDice(); |
|
|
|
c++; |
|
|
|
if(p.checkFigureInBase(p.figures) == 4 && dice == 6) { |
|
|
|
//choose |
|
|
|
//moveToStart |
|
|
|
int figId = p.choose() - 1; |
|
|
|
//checkIfKicked |
|
|
|
p.figures.get(figId).setPosition(p.startPos); |
|
|
|
} else { |
|
|
|
//choose |
|
|
|
int figId = p.choose() - 1; |
|
|
|
//moveToDice |
|
|
|
} |
|
|
|
} while (g.checkDice(dice, p, c)); |
|
|
@ -34,10 +35,10 @@ public class Game { |
|
|
|
this.gb = new Gameboard(); |
|
|
|
gb.initGameboard(); |
|
|
|
players = new ArrayList<>(); |
|
|
|
players.add(new Player("Rot", 40, 43)); |
|
|
|
players.add(new Player("Blau", 44, 47)); |
|
|
|
players.add(new Player("Gelb", 48, 51)); |
|
|
|
players.add(new Player("Grün", 52, 55)); |
|
|
|
players.add(new Player("Rot",0, 40, 43)); |
|
|
|
players.add(new Player("Blau",10, 44, 47)); |
|
|
|
players.add(new Player("Gelb",20, 48, 51)); |
|
|
|
players.add(new Player("Grün",30, 52, 55)); |
|
|
|
} |
|
|
|
|
|
|
|
public boolean checkDice(int dice, Player p, int countRolls) { |
|
|
|