find_bishop_attacks: Find set of bishop attacks

Description Usage Arguments Value Author(s)

View source: R/find_bishop_attacks.R

Description

Given a board state, a side and the bishop position, return every attacked squares by that bishop.

Usage

1
find_bishop_attacks(board, whites, square, queen = FALSE)

Arguments

board

A 12 by 64 binary matrix representing the game current status.

whites

If TRUE, the piece is a white piece, else blacks.

square

A character representing a square ("a1" to "h8").

queen

Internal parameter to be used when calculating queen moves. If TRUE, ignores the fact that no bishop exists in that position.

Value

A bitboard with all attacked squares.

Author(s)

Eduardo Kapp


eduardokapp/chessR documentation built on Dec. 20, 2021, 3:20 a.m.