Add rudimentary drop_tile and interactive mode

Adds basic drop_tile implementation. Though doesn't check for wins

Adds an interactive mode for testing drop_tile, which allows the player
to input which tile-space to drop on.
This commit is contained in:
Julia Lange 2024-07-14 03:51:47 -07:00
parent 5e86f3ccb9
commit 28a3188ea3
Signed by: Julia
SSH key fingerprint: SHA256:5DJcfxa5/fKCYn57dcabJa2vN2e6eT0pBerYi5SUbto
3 changed files with 39 additions and 7 deletions

8
main.c
View file

@ -5,6 +5,12 @@
int main(int argc, char *argv[])
{
struct Board *my_board = make_board(6, 7);
print_board(my_board);
while (1) {
print_board(my_board);
int drop_spot = 0;
printf("Where to drop? ");
scanf("%d",&drop_spot);
drop_tile(my_board, drop_spot-1);
}
return EXIT_SUCCESS;
}