1 /* src/client/command_db.h
3 * The Command DB collects the commands available to the user by internal name,
4 * description and, optionally, components of a message to send to the server
11 #include <stdint.h> /* uint8_t */
17 char * dsc_short; /* short name of command to be used internally */
18 char * dsc_long; /* long description of command to be shown to the user */
19 char * server_msg; /* optionally start string of message to send to server*/
20 char arg; /* defines server message suffix by player_control() convention */
25 struct Command * cmds; /* memory area for sequence of all Command structs */
26 uint8_t n; /* number of Command structs in database */
31 /* Return Command struct for command described by its "dsc_short" member. Return
32 * NULL if no such command is found.
34 extern struct Command * get_command(char * dsc_short);
36 /* Reads in CommandDB config file. */
37 extern void init_command_db();
39 /* Free all memory allocated with init_command_db. */
40 extern void free_command_db();