src/network/network_gamelist.h
author michi_cc
Mon, 20 Oct 2008 19:35:48 +0000
changeset 10269 eb8e4225dbc6
parent 9428 1ba05b499957
permissions -rw-r--r--
(svn r14504) -Cleanup: Use the right variable type for tile offsets.
2186
db48cf29b983 (svn r2701) Insert Id tags into all source files
tron
parents: 738
diff changeset
     1
/* $Id$ */
db48cf29b983 (svn r2701) Insert Id tags into all source files
tron
parents: 738
diff changeset
     2
9111
48ce04029fe4 (svn r12971) -Documentation: add @file in files that missed them and add something more than whitespace as description of files that don't have a description.
rubidium
parents: 6247
diff changeset
     3
/** @file network_gamelist.h Handling of the list of games. */
48ce04029fe4 (svn r12971) -Documentation: add @file in files that missed them and add something more than whitespace as description of files that don't have a description.
rubidium
parents: 6247
diff changeset
     4
543
946badd71033 (svn r942) -Merged branch/network back into the trunk
truelight
parents:
diff changeset
     5
#ifndef NETWORK_GAMELIST_H
946badd71033 (svn r942) -Merged branch/network back into the trunk
truelight
parents:
diff changeset
     6
#define NETWORK_GAMELIST_H
946badd71033 (svn r942) -Merged branch/network back into the trunk
truelight
parents:
diff changeset
     7
9428
1ba05b499957 (svn r13343) -Codechange: reorder/move variable/functions in the network headers so that nothing from the network directory needs to include basically all network headers.
rubidium
parents: 9111
diff changeset
     8
#include "network_type.h"
1ba05b499957 (svn r13343) -Codechange: reorder/move variable/functions in the network headers so that nothing from the network directory needs to include basically all network headers.
rubidium
parents: 9111
diff changeset
     9
5917
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    10
/** Structure with information shown in the game list (GUI) */
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    11
struct NetworkGameList {
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    12
	NetworkGameInfo info;  ///< The game information of this server
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    13
	uint32 ip;             ///< The IP of the game server
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    14
	uint16 port;           ///< The port of the game server
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    15
	bool online;           ///< False if the server did not respond (default status)
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    16
	bool manually;         ///< True if the server was added manually
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    17
	uint8 retries;         ///< Number of retries (to stop requerying)
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    18
	NetworkGameList *next; ///< Next pointer to make a linked game list
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    19
};
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    20
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    21
/** Game list of this client */
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    22
extern NetworkGameList *_network_game_list;
b0a9e5f20dcc (svn r8544) -Codechange: move game list related function/struct declarations to network_gamelist.h
rubidium
parents: 5897
diff changeset
    23
543
946badd71033 (svn r942) -Merged branch/network back into the trunk
truelight
parents:
diff changeset
    24
NetworkGameList *NetworkGameListAddItem(uint32 ip, uint16 port);
738
b96ab9e63d22 (svn r1194) Feature: You can now add and remove servers from the server list. Those will be remembered until you delete them by pressing the Delete key.
dominik
parents: 716
diff changeset
    25
void NetworkGameListRemoveItem(NetworkGameList *remove);
6247
7d81e3a5d803 (svn r9050) -Codechange: Foo(void) -> Foo()
rubidium
parents: 5917
diff changeset
    26
void NetworkGameListRequery();
543
946badd71033 (svn r942) -Merged branch/network back into the trunk
truelight
parents:
diff changeset
    27
946badd71033 (svn r942) -Merged branch/network back into the trunk
truelight
parents:
diff changeset
    28
#endif /* NETWORK_GAMELIST_H */