org.jscience.computing.game
Interface GameMove
- All Superinterfaces:
- java.io.Serializable
- All Known Implementing Classes:
- GameBoardMove, MoveTemplate
public interface GameMove
- extends java.io.Serializable
GameMove provides the necessary methods that allow a GamePlay
object to handle a game move properly. The only method defined is a method
to retrieve the game role associated with the move, as every move will have
to be played by a particular player. GameMove represents a move that can be
applied to a GamePlay object. GameMove extends Serializable to ensure that
a game and its moves can be used over e.g. an Internet connection or can be
written to a file. It is advised to also implement a useful
toString()
method, so that the moves will be displayed
properly.
- See Also:
GamePlay
,
MoveTemplate
Method Summary |
int |
getPlayer()
returns the game player role that plays this move |
getPlayer
int getPlayer()
- returns the game player role that plays this move
- See Also:
GamePlay.numberOfPlayers()