penguins  1.0.0
autonomous.h File Reference

Go to the source code of this file.

Detailed Description

The autonomous-mode machine interface.

See also
bot.h

Definition in file autonomous.h.

Enumerations

enum  AutonomousExitCode { EXIT_OK = 0 , EXIT_NO_POSSIBLE_MOVES = 1 , EXIT_INPUT_FILE_ERROR = 2 , EXIT_INTERNAL_ERROR = 3 }
 

Functions

int run_autonomous_mode (const Arguments *args)
 
bool load_game_state (Game *game, FILE *file, int penguins_arg, const char *my_player_name)
 
bool save_game_state (const Game *game, FILE *file)
 

Variables

const char * MY_AUTONOMOUS_PLAYER_NAME
 

Enumeration Type Documentation

◆ AutonomousExitCode

Enumerator
EXIT_OK 
EXIT_NO_POSSIBLE_MOVES 
EXIT_INPUT_FILE_ERROR 
EXIT_INTERNAL_ERROR 

Definition at line 16 of file autonomous.h.

Function Documentation

◆ run_autonomous_mode()

int run_autonomous_mode ( const Arguments args)

Definition at line 24 of file autonomous.c.

Referenced by main().

◆ load_game_state()

bool load_game_state ( Game game,
FILE *  file,
int  penguins_arg,
const char *  my_player_name 
)

Definition at line 142 of file autonomous.c.

Referenced by run_autonomous_mode().

◆ save_game_state()

bool save_game_state ( const Game game,
FILE *  file 
)

Definition at line 292 of file autonomous.c.

Referenced by run_autonomous_mode().

Variable Documentation

◆ MY_AUTONOMOUS_PLAYER_NAME

const char* MY_AUTONOMOUS_PLAYER_NAME
extern

Definition at line 17 of file autonomous.c.

Referenced by run_autonomous_mode().