kings_rook
The rook home position on the king's side.
queens_rook
The rook home position on the queen's side.
vectors may be added, subtracted, and multiplied by a constant.
ahead
The space immediately `ahead', meaning away from the home row of the color.
white_passant
(enemy(left) and pawn(left) and last(left + [0, 2], left)) or (enemy(right) and pawn(right) and last(right + [0, 2], right))
black_passant
(enemy(left) and pawn(left) and last(left - [0, 2], left)) or (enemy(right) and pawn(right) and last(right - [0, 2], right))
passant
(white and white_passant) or (black and black_passant)
The default action is for the piece to move to the destination and the enemy piece at that location to be removed. For specialty moves, these can be overridden.
It is assumed that any moves generated by these rules that produce off-board result positions are rejected.
mutate
After the move, mutat to the designated piece (used for pawn promotion in standard chess).
Pawns:
[ahead] if empty; [ahead * 2] if empty and clear and home; [ahead + left] if enemy or passant; [ahead + right] if enemy or passant.
Rooks:
[0, ?] if clear and not friend; [?, 0] if clear and not friend.
Knights:
[+1, +2] if not friend; [+1, -2] if not friend; [-1, +2] if not friend; [-1, -2] if not friend; [+2, +1] if not friend; [+2, -1] if not friend; [-2, +1] if not friend; [-2, -1] if not friend.
Bishops:
[?, ?] if clear and not friend; [?, -?] if clear and not friend.
Queens:
[0, ?] if clear and not friend; [?, 0] if clear and not friend. [?, ?] if clear and not friend; [?, -?] if clear and not friend.
Kings:
[-1, -1] if not friend and not threat; [-1, 0] if not friend and not threat; [-1, +1] if not friend and not threat; [ 0, -1] if not friend and not threat; [ 0, +1] if not friend and not threat; [+1, -1] if not friend and not threat; [+1, 0] if not friend and not threat; [+1, +1] if not friend and not threat; [king * 2] if home and home[kings_rook] and clear[king, kings_rook]; [queen * 3] if home and home[queens_rook] and clear[king, queens_rook];
We still need notations for the rook movements during castling.
Globally: not threat[king];
not threat[king]
2 POD Errors
The following errors were encountered while parsing the POD:
'=item' outside of any '=over'
You forgot a '=back' before '=head2'
To install Games::Chess::Referee, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Games::Chess::Referee
CPAN shell
perl -MCPAN -e shell install Games::Chess::Referee
For more information on module installation, please visit the detailed CPAN module installation guide.