public class MovementFactory
extends java.lang.Object
| Constructor and Description |
|---|
MovementFactory() |
| Modifier and Type | Method and Description |
|---|---|
protected static java.util.Collection |
generateMoves(Move base) |
static Move[] |
getAllMoves(int player,
Dice dice,
Board board)
Returns all possible distinct moves for the given player
given the starting board and the given dice roll.
|
static boolean |
movePossible(int die,
int player,
Board board)
Return whether or not a move is possible using
the given dice roll by the given player in the given board.
|
public static boolean movePossible(int die,
int player,
Board board)
int - die The dice rollplayer - The playerboard - The boardpublic static Move[] getAllMoves(int player, Dice dice, Board board)
player - The player who is activedice - The dice rollboard - The current boardprotected static java.util.Collection generateMoves(Move base)