|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IChessEnvironment
Defines methods required by chess environments in the 3D chess framework.
Method Summary | |
---|---|
void |
addCheckListener(ICheckListener listener)
Add the given listener. |
IChessAgent |
getAgent(boolean isWhite)
Return the proper agent for the given flag. |
IChessAgent |
getAgentBlack()
Return the agent for the black team. |
IChessAgent |
getAgentWhite()
Return the agent for the white team. |
int |
getEnPassantRank(boolean isWhite)
Return the en passant capture rank (if any) for the given parameter. |
List |
getHintPositionsFor(IntegerPosition position,
IAdjudicator adjudicator)
Return the hint positions for the given position. |
IntegerPosition |
getInitialKingPosition(boolean isWhite)
Return the initial King position. |
IntegerPosition |
getInitialKingsRookPosition(boolean isWhite)
Return the initial King's rook position. |
IntegerPosition |
getInitialQueensRookPosition(boolean isWhite)
Return the initial Queen's rook position. |
int |
getKingsCastleDeltaFile(boolean isKingSide)
Return the King's delta file for either king-side or queen-side castling. |
IChessAgent |
getOpponent(IChessAgent agent)
Return the opposing agent to the given agent. |
int |
getRooksCastleDeltaFile(boolean isKingSide)
Return the Rook's delta file for either king-side or queen-side castling. |
ITeam |
getTeamBlack()
Return the team for black. |
ITeam |
getTeamWhite()
Return the team for white. |
boolean |
isCastlingAllowed()
Return true if this environment allows castling. |
boolean |
isEnPassantCaptureAllowed()
Return true if this environment allows en passant capture. |
boolean |
isFiringChecks()
Return true if this is set to fire check events. |
boolean |
isInitialPosition(Class tokenClass,
ITeam team,
IntegerPosition position)
Return true if the given coordinates are the initial position for a token of the given class. |
boolean |
isPawnInitialPosition(ITeam team,
IntegerPosition position)
Return true if the given coordinates are the initial position for a Pawn. |
void |
removeCheckListener(ICheckListener listener)
Remove the given listener. |
void |
setFiringChecks(boolean fire)
Set the flag which indicates whether to fire state change events. |
Methods inherited from interface org.vizzini.game.boardgame.IGridBoard |
---|
agentTokenCount, coordsToIndex, get, getCellCount, getFileCount, getLastAgent, getLevelCount, getMaxDimension, getRankCount, indexToFile, indexToLevel, indexToPosition, indexToRank, is3D, isActionHistoryUsed, isPositionUsable, isPositionUsable, isRedoAllowed, isUndoAllowed, positionToIndex, setActionHistoryUsed, setToken, setToken |
Methods inherited from interface org.vizzini.game.IEnvironment |
---|
addStateListener, clone, configure, copy, get, getAdjudicator, getAgentCollection, getTeamCollection, getTokenCollection, getTurnNumber, incrementTurnNumber, isFiringStateChanges, open, performAction, performActions, removeStateListener, reset, setAdjudicator, setAgentCollection, setFiringStateChanges, setTurnNumber, undoAction, update |
Method Detail |
---|
void addCheckListener(ICheckListener listener)
IChessAgent getAgent(boolean isWhite)
isWhite
- Flag indicating whether to return the white agent.IChessAgent getAgentBlack()
IChessAgent getAgentWhite()
int getEnPassantRank(boolean isWhite)
isWhite
- Flag indicating whether White or Black.
List getHintPositionsFor(IntegerPosition position, IAdjudicator adjudicator)
IntegerPosition getInitialKingPosition(boolean isWhite)
IntegerPosition getInitialKingsRookPosition(boolean isWhite)
IntegerPosition getInitialQueensRookPosition(boolean isWhite)
int getKingsCastleDeltaFile(boolean isKingSide)
IChessAgent getOpponent(IChessAgent agent)
int getRooksCastleDeltaFile(boolean isKingSide)
ITeam getTeamBlack()
ITeam getTeamWhite()
boolean isCastlingAllowed()
boolean isEnPassantCaptureAllowed()
boolean isFiringChecks()
boolean isInitialPosition(Class tokenClass, ITeam team, IntegerPosition position)
boolean isPawnInitialPosition(ITeam team, IntegerPosition position)
void removeCheckListener(ICheckListener listener)
void setFiringChecks(boolean fire)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright © 2007 Vizzini.org. All Rights Reserved. | 2007.12.25.03.00.02 |