Fix for the problem that SDL applications exited
[AROS-Contrib.git] / Games / lbreakout2 / client / player.h
blob25f5136125b7efa70ecea647a9af25328b2f7d6f
1 /***************************************************************************
2 player.h - description
3 -------------------
4 begin : Thu Sep 6 2001
5 copyright : (C) 2001 by Michael Speck
6 email : kulkanie@gmx.net
7 ***************************************************************************/
9 /***************************************************************************
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 ***************************************************************************/
19 ====================================================================
20 Add this player to the list and increase the counter until
21 MAX_PLAYERS is reached.
22 Return Value: True if successful
23 ====================================================================
25 int player_add( char *name, int lives, Level *level );
27 ====================================================================
28 Get first player. (and set current id to 0)
29 Return Value: first player in list
30 ====================================================================
32 Player* players_get_first();
34 ====================================================================
35 Get next player in list (cycle: return first player after
36 last player, update current id).
37 Return Value: current player
38 ====================================================================
40 Player* players_get_next();
42 ====================================================================
43 player_count players give id's 0,1,...,player_count-1. Select
44 the player with id 'current' as current player. The id used is
45 the absolute one, not the relative one resulting from dead players.
46 Return Value: current player
47 ====================================================================
49 Player* players_set_current( int current );
51 ====================================================================
52 Reset player counter.
53 ====================================================================
55 void players_clear();
57 ====================================================================
58 Return number of players still in game (lives > 0)
59 ====================================================================
61 int players_count();
63 /* set level_id and init snapshot with the new leveldata */
64 void player_init_level( Player *player, Level *level, int id );