merge the new developmentbranch into the test branch #39
@@ -18,17 +18,17 @@ public class Die {
|
||||
/**
|
||||
* The probability of rolling a zero eye.
|
||||
*/
|
||||
public static final double ZERO_EYE = 0.2;
|
||||
public static final double ZERO_EYE = 0;
|
||||
|
||||
/**
|
||||
* The probability of rolling a normal eye.
|
||||
*/
|
||||
public static final double NORMAL_EYE = 0.2;
|
||||
public static final double NORMAL_EYE = 0;
|
||||
|
||||
/**
|
||||
* The probability of rolling a double eye.
|
||||
*/
|
||||
public static final double DOUBLE_EYE = 0.6;
|
||||
public static final double DOUBLE_EYE = 1;
|
||||
|
||||
/**
|
||||
* The modifier applied to the die roll.
|
||||
|
||||
@@ -87,7 +87,7 @@ public Game() {
|
||||
gameStatistics = new Statistic();
|
||||
initializeDrawPile();
|
||||
board = new Board();
|
||||
die = new Die();
|
||||
die = new Die(1,6,6,6,6);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -95,8 +95,8 @@ public Game() {
|
||||
*/
|
||||
private void initializeDrawPile() {
|
||||
this.addBonusCards(new TurboCard(), AMOUNT_OF_TURBO_CARDS);
|
||||
this.addBonusCards(new SwapCard(), AMOUNT_OF_SWAP_CARDS);
|
||||
this.addBonusCards(new ShieldCard(), AMOUNT_OF_SHIELD_CARDS);
|
||||
// this.addBonusCards(new SwapCard(), AMOUNT_OF_SWAP_CARDS);
|
||||
// this.addBonusCards(new ShieldCard(), AMOUNT_OF_SHIELD_CARDS);
|
||||
Collections.shuffle(this.drawPile);
|
||||
}
|
||||
|
||||
|
||||
@@ -4,6 +4,10 @@
|
||||
import pp.mdga.game.Piece;
|
||||
import pp.mdga.game.PieceState;
|
||||
import pp.mdga.game.Player;
|
||||
import pp.mdga.game.card.PowerCard;
|
||||
import pp.mdga.game.card.ShieldCard;
|
||||
import pp.mdga.game.card.SwapCard;
|
||||
import pp.mdga.game.card.TurboCard;
|
||||
import pp.mdga.message.client.*;
|
||||
import pp.mdga.message.server.*;
|
||||
import pp.mdga.server.ServerGameLogic;
|
||||
@@ -52,6 +56,15 @@ public void initializeGame() {
|
||||
for (var player : this.logic.getGame().getPlayers().values()) {
|
||||
player.initialize();
|
||||
player.addHandCard(this.logic.getGame().draw());
|
||||
//TODO
|
||||
player.addHandCard(new ShieldCard());
|
||||
player.addHandCard(new ShieldCard());
|
||||
player.addHandCard(new TurboCard());
|
||||
player.addHandCard(new TurboCard());
|
||||
player.addHandCard(new SwapCard());
|
||||
player.addHandCard(new SwapCard());
|
||||
|
||||
|
||||
Piece piece = player.getPieces()[0];
|
||||
player.getWaitingArea()[0] = null;
|
||||
piece.setState(PieceState.ACTIVE);
|
||||
|
||||
Reference in New Issue
Block a user