Chess 0.0.1
A library written in c
|
Defines the chess color type and related utility functions for representing and manipulating chess colors. More...
Go to the source code of this file.
Enumerations | |
enum | ChessColor : uint8_t { CHESS_COLOR_WHITE = 0 , CHESS_COLOR_BLACK = 1 , CHESS_COLOR_NONE = 2 } |
Represents the color of a chess piece, square or player. More... | |
Functions | |
void | chess_color_debug (ChessColor color) |
Prints a debug representation of the given color. | |
bool | chess_color_is_valid (ChessColor color) |
Checks if the given color is valid (white or black). | |
ChessColor | chess_color_opposite (ChessColor color) |
Returns the opposite color (white <-> black). | |
Defines the chess color type and related utility functions for representing and manipulating chess colors.
enum ChessColor : uint8_t |
void chess_color_debug | ( | ChessColor | color | ) |
Prints a debug representation of the given color.
color | The color to print. |
bool chess_color_is_valid | ( | ChessColor | color | ) |
Checks if the given color is valid (white or black).
color | The color to check. |
ChessColor chess_color_opposite | ( | ChessColor | color | ) |
Returns the opposite color (white <-> black).
color | The color to invert. |