# HG changeset patch # User Darkvater # Date 1146321076 0 # Node ID 01468bf49e8ba6d71e8d93198d3ed39b282dc99b # Parent 7e1ad0718ed801f8ca3ad0a6d4e4f8cf4133dbc5 (svn r4623) - Codechange: s/byte/PlayerID/ diff -r 7e1ad0718ed8 -r 01468bf49e8b ai/ai.c --- a/ai/ai.c Sat Apr 29 09:47:43 2006 +0000 +++ b/ai/ai.c Sat Apr 29 14:31:16 2006 +0000 @@ -11,7 +11,7 @@ /** * Dequeues commands put in the queue via AI_PutCommandInQueue. */ -static void AI_DequeueCommands(byte player) +static void AI_DequeueCommands(PlayerID player) { AICommand *com, *entry_com; diff -r 7e1ad0718ed8 -r 01468bf49e8b main_gui.c --- a/main_gui.c Sat Apr 29 09:47:43 2006 +0000 +++ b/main_gui.c Sat Apr 29 14:31:16 2006 +0000 @@ -580,7 +580,7 @@ } } -extern void DrawPlayerIcon(int p, int x, int y); +extern void DrawPlayerIcon(PlayerID pid, int x, int y); static void PlayerMenuWndProc(Window *w, WindowEvent *e) { diff -r 7e1ad0718ed8 -r 01468bf49e8b misc_gui.c --- a/misc_gui.c Sat Apr 29 09:47:43 2006 +0000 +++ b/misc_gui.c Sat Apr 29 14:31:16 2006 +0000 @@ -1719,7 +1719,7 @@ { WIDGETS_END}, }; -extern void DrawPlayerIcon(int p, int x, int y); +extern void DrawPlayerIcon(PlayerID pid, int x, int y); static void CheatsWndProc(Window *w, WindowEvent *e) { diff -r 7e1ad0718ed8 -r 01468bf49e8b network.h --- a/network.h Sat Apr 29 09:47:43 2006 +0000 +++ b/network.h Sat Apr 29 14:31:16 2006 +0000 @@ -222,7 +222,7 @@ VARDEF bool _network_available; // is network mode available? VARDEF bool _network_server; // network-server is active VARDEF bool _network_dedicated; // are we a dedicated server? -VARDEF byte _network_playas; // an id to play as.. +VARDEF PlayerID _network_playas; // an id to play as.. void ParseConnectionString(const char **player, const char **port, char *connection_string); void NetworkUpdateClientInfo(uint16 client_index); diff -r 7e1ad0718ed8 -r 01468bf49e8b network_client.c --- a/network_client.c Sat Apr 29 09:47:43 2006 +0000 +++ b/network_client.c Sat Apr 29 14:31:16 2006 +0000 @@ -327,7 +327,7 @@ { NetworkClientInfo *ci; uint16 index = NetworkRecv_uint16(MY_CLIENT, p); - byte playas = NetworkRecv_uint8(MY_CLIENT, p); + PlayerID playas = NetworkRecv_uint8(MY_CLIENT, p); char name[NETWORK_NAME_LENGTH]; char unique_id[NETWORK_NAME_LENGTH]; diff -r 7e1ad0718ed8 -r 01468bf49e8b network_gui.c --- a/network_gui.c Sat Apr 29 09:47:43 2006 +0000 +++ b/network_gui.c Sat Apr 29 14:31:16 2006 +0000 @@ -27,7 +27,7 @@ #define BTC 15 typedef struct network_d { - byte company; // select company in network lobby + PlayerID company; // select company in network lobby byte field; // select text-field in start-server and game-listing NetworkGameList *server; // selected server in lobby and game-listing FiosItem *map; // selected map in start-server @@ -1004,7 +1004,7 @@ // and also makes able to give money to them, kick them (if server) // and stuff like that. -extern void DrawPlayerIcon(int p, int x, int y); +extern void DrawPlayerIcon(PlayerID pid, int x, int y); // Every action must be of this form typedef void ClientList_Action_Proc(byte client_no); diff -r 7e1ad0718ed8 -r 01468bf49e8b town_gui.c --- a/town_gui.c Sat Apr 29 09:47:43 2006 +0000 +++ b/town_gui.c Sat Apr 29 14:31:16 2006 +0000 @@ -29,7 +29,7 @@ }; extern const byte _town_action_costs[8]; -extern void DrawPlayerIcon(int p, int x, int y); +extern void DrawPlayerIcon(PlayerID pid, int x, int y); /** Get a list of available actions to do at a town. * @param *nump if not NULL add put the number of available actions in it