summaryrefslogtreecommitdiff
path: root/src/2048.h
blob: 9b19f6481860dd99003fc6d6f585751b672a0f41 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#define SIZE 4

int move(int direction, int board[SIZE][SIZE]);

void init(int board[SIZE][SIZE]);

void add2(int board[SIZE][SIZE]);

void rotate(int board[SIZE][SIZE]);

int slideLeft(int board[SIZE][SIZE]);
int slideRight(int board[SIZE][SIZE]);
int slideUp(int board[SIZE][SIZE]);
int slideDown(int board[SIZE][SIZE]);
int gameover(int board[SIZE][SIZE]);

int push(int array[SIZE]);