vutbr.checkers.game
Class GamePieceKing
java.lang.Object
vutbr.checkers.game.GamePiece
vutbr.checkers.game.GamePieceKing
public class GamePieceKing
- extends GamePiece
Trida GamePieceKing - figurka kralovny
- Author:
- Ondřej Choleva
Method Summary |
protected boolean |
possibleTurn(int toX,
int toY,
GameTurnState gameTurnState)
Overi, zda je tento tah kralovnou mozny |
protected boolean |
turn(int toX,
int toY,
GameTurnState gameTurnState)
Provede tah kralovnou |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GamePieceKing
public GamePieceKing(GameBoard board,
int x,
int y,
Game.GameColor color)
- Konstruktur
- Parameters:
board
- Hraci plochax
- Souradnice Xy
- Souradnice Ycolor
- Barva figurky
turn
protected boolean turn(int toX,
int toY,
GameTurnState gameTurnState)
- Provede tah kralovnou
- Specified by:
turn
in class GamePiece
- Parameters:
toX
- Cilova souradnice XtoY
- Cilova souradnice YgameTurnState
- Stav tahu hry
- Returns:
- True pokud se tah povedl
possibleTurn
protected boolean possibleTurn(int toX,
int toY,
GameTurnState gameTurnState)
- Overi, zda je tento tah kralovnou mozny
- Parameters:
toX
- Cilova souradnice XtoY
- Cilova souradnice YgameTurnState
- Stav tahu hry
- Returns:
- True pokud je tah mozny