Modifier and Type | Method and Description |
---|---|
int |
Die.compareTo(Die other)
Compares two dice by their face value.
|
Modifier and Type | Method and Description |
---|---|
static boolean |
Yahtzee.isFiveOfAKind(List<Die> dice)
Returns
true if the list contains a five of a kind. |
static boolean |
Yahtzee.isFourOfAKind(List<Die> dice)
Returns
true if the list contains a four of a kind. |
static boolean |
Yahtzee.isFullHouse(List<Die> dice)
Returns
true if the list contains a full house. |
static boolean |
Yahtzee.isLargeStraight(List<Die> dice)
Returns
true if the list contains a large straight. |
static boolean |
Yahtzee.isSmallStraight(List<Die> dice)
Returns
true if the list contains a small straight. |
static boolean |
Yahtzee.isThreeOfAKind(List<Die> dice)
Returns
true if the list contains a three of a kind. |
Constructor and Description |
---|
Die(Die d)
Create a die that has the same number of faces and same value
as another die.
|