HTMLify

ttt.h
Views: 15 | Author: abh
#ifndef TTT_H
#define TTT_H

#include <stdbool.h>

typedef struct {
    char state[9];
    char *player1;
    char *player2;
    char symbols[2];
    int turn;
    bool running;
} TTT;

TTT *TTT_init(const char* player1, const char* player2, const char player1_symbol, const char player2_symbol, int turn);

bool TTT_mark(TTT *, int pos);

int TTT_check_win(TTT *);

void TTT_bot_turn(TTT *);

#endif

Comments