code_snippets/c_projects/tiktaktoe/include/tiktaktoe.h
2026-01-02 16:41:22 -08:00

30 lines
524 B
C

#ifndef TIKTAKTOE_H
#define TIKTAKTOE_H
#include <ncurses.h>
#include <stdint.h>
#define GRIDSIZE 3
#define HEADERSIZE 5
#define FOOTERSIZE 5
extern const char game_end;
typedef struct w_data_t{
WINDOW *w_ptr;
int height;
int width;
}w_data_t;
// gamelogic
int start_tiktaktoe(void);
void get_input(w_data_t *board);
// render
void init_windows(w_data_t *board, w_data_t *header, w_data_t *footer);
void create_grid(w_data_t *currwin);
void draw_board(w_data_t *board, w_data_t *header, w_data_t *footer);
#endif