Files
Gruppe-01-fin/Projekte/mdga/model/src/main/java/pp.mdga/notification/RollDiceNotification.java
2024-11-30 00:33:10 +01:00

58 lines
1.3 KiB
Java

package pp.mdga.notification;
import pp.mdga.game.Color;
/**
* Notification that a dice has been rolled.
*/
public class RollDiceNotification extends Notification{
private Color color;
private int eyes;
private boolean turbo;
private int multiplier;
/**
* Constructor.
* @param color the color of the player that rolled the die.
* @param eyes the number of eyes that were rolled.
*/
RollDiceNotification(Color color, int eyes) {
this.color = color;
this.eyes = eyes;
this.multiplier = -1;
this.turbo = false;
}
RollDiceNotification(Color color, int eyes, boolean turbo, int multiplier) {
this.color = color;
this.eyes = eyes;
this.multiplier = multiplier;
this.turbo = turbo;
}
/**
* Get the color of the player that rolled the die.
* @return the color of the player that rolled the die.
*/
public Color getColor() {
return color;
}
/**
* Get the number of eyes that were rolled.
* @return the number of eyes that were rolled.
*/
public int getEyes() {
return eyes;
}
public int getMultiplier() {
return multiplier;
}
public boolean isTurbo() {
return turbo;
}
}