Module inanis::state::movescan

source ·

Modules

Structs

Functions

  • Gets PIECE mobility (by counting all possible moves at the position specified by board) with color and increases dangered_king_squares if the enemy king is near to the squares included in the mobility.
  • Generates all possible non-captures (if CAPTURES is false) or all possible captures (if CAPTURES is true) for the pawns at the position specified by board, stores them into moves list (starting from index) and returns index of the first free slot. Use evasion_mask with value different than u64::MAX to restrict generator to the specified squares (useful during checks).
  • Generates all possible captures for the pawns toward the direction specified by DIR and at the position specified by board, stores them into moves list (starting from index) and returns index of the first free slot. Use evasion_mask with value different than u64::MAX to restrict generator to the specified squares (useful during checks).
  • Generates all possible double pushes for the pawns at the position specified by board, stores them into moves list (starting from index) and returns index of the first free slot. Use evasion_mask with value different than u64::MAX to restrict generator to the specified squares (useful during checks).
  • Generates all possible single pushes for the pawns at the position specified by board, stores them into moves list (starting from index) and returns index of the first free slot. Use evasion_mask with value different than u64::MAX to restrict generator to the specified squares (useful during checks).
  • Generates all possible non-captures (if CAPTURES is false) or all possible captures (if CAPTURES is true) for the PIECE at the position specified by board, stores them into moves list (starting from index) and returns index of the first free slot. Use evasion_mask with value different than u64::MAX to restrict generator to the specified squares (useful during checks).