blob: 57a6440296992ae8882edbc7de4b580f9028c81d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
#include "vector.h"
#ifndef CHESS_HELPERS
#define CHESS_HELPERS
typedef enum {
pawn = 1,
knight = 2,
bishop = 3,
rook = 4,
queen = 5,
king = 6,
} piece_t;
int in_board(vector_t position);
int is_empty(int board[8][8], vector_t position);
int is_color(int board[8][8], vector_t position, int color);
char* get_readable_coords(vector_t position);
char* get_move_name(int board[8][8], vector_t origin, vector_t end);
#endif
|