Uses of Class
net.royalur.model.Piece
Package
Description
-
Uses of Piece in net.royalur
Modifier and TypeMethodDescriptionGame.findMoveByPiece
(Piece piece) Finds the move of the piecepiece
.void
Moves the piecepiece
, and updates the state of the game. -
Uses of Piece in net.royalur.model
Modifier and TypeMethodDescriptionGets the piece ontile
.Board.getByIndices
(int ix, int iy) Gets the piece on the tile at the indices (ix
,iy
), 0-based.Move.getCapturedPiece()
Gets the piece that will be captured by this move.Move.getCapturedPieceOrNull()
Gets the piece that will be captured by this move, or null if there is no piece that will be captured.Move.getDestPiece()
Gets the destination piece of this move.Move.getDestPieceOrNull()
Gets the destination piece of this move, or null if there is no destination piece, in the case where a piece is moved off the board.Move.getSourcePiece()
Gets the source piece of this move.Move.getSourcePieceOrNull()
Gets the source piece of this move, or null if there is no source piece, in the case where a new piece is moved onto the board.Sets the piece ontile
topiece
.Board.setByIndices
(int ix, int iy, Piece piece) Sets the piece on the tile at the indices (ix
,iy
), 0-based, to the piecepiece
.Modifier and TypeMethodDescriptionSets the piece ontile
topiece
.Board.setByIndices
(int ix, int iy, Piece piece) Sets the piece on the tile at the indices (ix
,iy
), 0-based, to the piecepiece
.static char
Convertspiece
to a single character that can be used to textually represent the owner of a piece. -
Uses of Piece in net.royalur.notation
Modifier and TypeMethodDescriptionJsonNotation.readNullablePiece
(RuleSet rules, com.fasterxml.jackson.databind.node.ObjectNode json, String key) JsonNotation.readOldPiece
(RuleSet rules, com.fasterxml.jackson.databind.node.ObjectNode json) JsonNotation.readPiece
(RuleSet rules, com.fasterxml.jackson.databind.node.ObjectNode json, String key) Modifier and TypeMethodDescriptionint
JsonNotation.encodePiece
(Piece piece) protected void
JsonNotation.writePieceField
(com.fasterxml.jackson.core.JsonGenerator generator, String fieldName, Piece piece) -
Uses of Piece in net.royalur.rules
Modifier and TypeMethodDescriptionPieceProvider.create
(PlayerType owner, int pathIndex) Generate a piece on the board.PieceProvider.createIntroduced
(PlayerType owner, int newPathIndex) Generates a new piece to be introduced to the board.PieceProvider.createMoved
(Piece originPiece, int newPathIndex) Generates a piece that has been moved from another tile on the board.Modifier and TypeMethodDescriptionPlayerStateProvider.applyPieceCaptured
(PlayerState playerState, Piece piece) Generates a new player state that is a copy ofplayerState
, with the given piece captured.PlayerStateProvider.applyPieceIntroduced
(PlayerState playerState, Piece piece) Generates a new player state that is a copy ofplayerState
, with the given piece introduced to the board.PlayerStateProvider.applyPieceScored
(PlayerState playerState, Piece piece) Generates a new player state that is a copy ofplayerState
, with the given piece scored.PieceProvider.createMoved
(Piece originPiece, int newPathIndex) Generates a piece that has been moved from another tile on the board. -
Uses of Piece in net.royalur.rules.simple
Modifier and TypeMethodDescriptionSimplePieceProvider.create
(PlayerType owner, int pathIndex) SimplePieceProvider.createIntroduced
(PlayerType owner, int newPathIndex) SimplePieceProvider.createMoved
(Piece fromPiece, int newPathIndex) Modifier and TypeMethodDescriptionSimplePlayerStateProvider.applyPieceCaptured
(PlayerState playerState, Piece piece) SimplePlayerStateProvider.applyPieceIntroduced
(PlayerState playerState, Piece piece) SimplePlayerStateProvider.applyPieceScored
(PlayerState playerState, Piece piece) SimplePieceProvider.createMoved
(Piece fromPiece, int newPathIndex)