[ List Earliest Comments Only For Pages | Games | Rated Pages | Rated Games | Subjects of Discussion ]
Check out Janggi (Korean Chess), our featured variant for December, 2024.
Check out Janggi (Korean Chess), our featured variant for December, 2024.
out where it is, and then check this square with the "attacked?" command.
But if you only need to know whether a certain enemy piece is attacking your
king, you could perhaps use the same principle as I use in
Coordinator Chess, for instance. I have added a "king gaze" move to the king's
definition, at a lower priority than standard moves, so the king never
performs them. Other pieces can then check if the king "sees" an enemy piece on the
diagonal or the orthogonal, or the knight jump.
M. Winther