src/chess/knight.h

changeset 169
9962f5d98764
parent 163
2a6d83f4677e
child 170
bde99d803caf
--- a/src/chess/knight.h	Sun Aug 02 15:19:47 2026 +0200
+++ b/src/chess/knight.h	Thu Aug 06 14:45:55 2026 +0200
@@ -39,6 +39,11 @@
 bool knight_chkrules(const Move *move);
 #define knight_isblocked(gs,m) false
 
+#define KNIGHT_MOVES_MAX 8
+size_t knight_moves(GameState *gamestate, Color c, Row r, File f, Move *moves);
+#define knight_moves_allowed(gamestate, color, row, file, moves) \
+    filter_moves_allowed(gamestate, color, row, file, moves, knight_moves)
+
 #ifdef	__cplusplus
 }
 #endif

mercurial