project_files/frontlib/model/roomlist.h
changeset 7275 15f722e0b96f
parent 7269 5b0aeef8ba2a
child 7314 6171f0bad318
equal deleted inserted replaced
7273:8eed495fd8da 7275:15f722e0b96f
    14     int teamCount;
    14     int teamCount;
    15     char *owner;
    15     char *owner;
    16     char *map;			// This is either a map name, or one of +rnd+, +maze+ or +drawn+.
    16     char *map;			// This is either a map name, or one of +rnd+, +maze+ or +drawn+.
    17     char *scheme;
    17     char *scheme;
    18     char *weapons;
    18     char *weapons;
    19 } flib_roomlist_room;
    19 } flib_room;
    20 
    20 
    21 typedef struct {
    21 typedef struct {
    22 	int roomCount;
    22 	int roomCount;
    23 	flib_roomlist_room **rooms;
    23 	flib_room **rooms;
    24 } flib_roomlist;
    24 } flib_roomlist;
    25 
    25 
    26 flib_roomlist *flib_roomlist_create();
    26 flib_roomlist *flib_roomlist_create();
    27 
    27 
    28 void flib_roomlist_destroy(flib_roomlist *list);
    28 void flib_roomlist_destroy(flib_roomlist *list);
    43 int flib_roomlist_update(flib_roomlist *list, const char *name, char **params);
    43 int flib_roomlist_update(flib_roomlist *list, const char *name, char **params);
    44 
    44 
    45 /**
    45 /**
    46  * Returns the room with the name [name] from the list if it exists, NULL otherwise
    46  * Returns the room with the name [name] from the list if it exists, NULL otherwise
    47  */
    47  */
    48 flib_roomlist_room *flib_roomlist_find(flib_roomlist *list, const char *name);
    48 flib_room *flib_roomlist_find(const flib_roomlist *list, const char *name);
    49 
    49 
    50 /**
    50 /**
    51  * Removes all rooms from the list
    51  * Removes all rooms from the list
    52  */
    52  */
    53 void flib_roomlist_clear(flib_roomlist *list);
    53 void flib_roomlist_clear(flib_roomlist *list);