diff options
Diffstat (limited to 'include/othello.h')
-rw-r--r-- | include/othello.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/include/othello.h b/include/othello.h new file mode 100644 index 0000000..aed7302 --- /dev/null +++ b/include/othello.h @@ -0,0 +1,19 @@ +#include <stdbool.h> + +typedef char player_color; +#define EMPTY (player_color)'*' +#define WHITE (player_color)'w' +#define BLACK (player_color)'b' + +struct move { + int row; + int col; +}; + +void initialize_board(player_color board[8][8]); +bool is_valid_move(const player_color board[8][8], + const player_color current_player, const struct move move); +bool has_valid_moves(const player_color board[8][8], + const player_color current_player); +char game_loop(player_color board[8][8]); +void print_board(player_color board[8][8]); |