manager
Class DeflexionGame
java.lang.Object
manager.Game
manager.DeflexionGame
public class DeflexionGame
- extends Game
This class extends the generic board game class Game
to support a deflexion game.
- Version:
- 0.5 beta - 03/15/2006
- Author:
- Luciano Antonio Digiampietri
- See Also:
Game
Fields inherited from class manager.Game |
BOARD, CONT_ID, DRAWN_GAME, GAME_ENDED, GAME_STARTED, GAME_TYPE, LAST_MESSAGE, MAX_PLAYERS, MIN_PLAYERS, PLAYERS, WAITING_PLAYERS, WINNER |
Method Summary |
boolean |
add(int x,
int y,
java.lang.String Player)
|
void |
auxDisparLaser(int x,
int y,
java.lang.String laser_orientation)
|
boolean |
burn(int x,
int y)
|
boolean |
canAdd(int x,
int y,
Piece P)
|
boolean |
canMove(int x1,
int y1,
int x2,
int y2,
int Player)
|
boolean |
canRotate(int x,
int y,
int Player)
|
boolean |
disparLaser(int Player)
|
boolean |
endTurn(int Player)
|
boolean |
gameEnded()
|
void |
initializeBoard()
|
void |
insertPieces()
|
boolean |
move(int x1,
int y1,
int x2,
int y2,
int Player)
|
boolean |
player1Won()
|
boolean |
player2Won()
|
boolean |
rotate(int x,
int y,
java.lang.String direction,
int Player)
|
void |
startGame()
|
boolean |
won(int Player)
|
Methods inherited from class manager.Game |
add, canAdd, currentBoard, gameDraw, getActualPlayer, getColumns, getCurrentGameId, getGameName, getGameType, getLines, getMaxPlayers, getMessage, getMinPlayers, getPlayers, getStatus, joinGame, waitingPlayers |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CLOCKWISE
public static final java.lang.String CLOCKWISE
- See Also:
- Constant Field Values
ANTICLOCKWISE
public static final java.lang.String ANTICLOCKWISE
- See Also:
- Constant Field Values
DeflexionGame
public DeflexionGame(java.lang.String name)
DeflexionGame
public DeflexionGame(java.lang.String name,
int player1)
startGame
public void startGame()
endTurn
public boolean endTurn(int Player)
- Overrides:
endTurn
in class Game
move
public boolean move(int x1,
int y1,
int x2,
int y2,
int Player)
- Overrides:
move
in class Game
canMove
public boolean canMove(int x1,
int y1,
int x2,
int y2,
int Player)
- Overrides:
canMove
in class Game
canRotate
public boolean canRotate(int x,
int y,
int Player)
rotate
public boolean rotate(int x,
int y,
java.lang.String direction,
int Player)
- Overrides:
rotate
in class Game
burn
public boolean burn(int x,
int y)
disparLaser
public boolean disparLaser(int Player)
auxDisparLaser
public void auxDisparLaser(int x,
int y,
java.lang.String laser_orientation)
canAdd
public boolean canAdd(int x,
int y,
Piece P)
add
public boolean add(int x,
int y,
java.lang.String Player)
initializeBoard
public void initializeBoard()
- Overrides:
initializeBoard
in class Game
insertPieces
public void insertPieces()
gameEnded
public boolean gameEnded()
- Overrides:
gameEnded
in class Game
player2Won
public boolean player2Won()
player1Won
public boolean player1Won()
won
public boolean won(int Player)