From 99a11badaf80f6f3a7ddaec74ca7fad712b28957 Mon Sep 17 00:00:00 2001 From: rubidium Date: Sat, 19 Jun 2010 16:37:56 +0000 Subject: (svn r19996) -Codechange: Add NetworkVehicleType enum. --- src/network/network_gui.cpp | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'src/network/network_gui.cpp') diff --git a/src/network/network_gui.cpp b/src/network/network_gui.cpp index f2c70f1eb..db071c28e 100644 --- a/src/network/network_gui.cpp +++ b/src/network/network_gui.cpp @@ -1603,15 +1603,19 @@ struct NetworkLobbyWindow : public Window { DrawString(r.left + WD_FRAMERECT_LEFT, r.right - WD_FRAMERECT_RIGHT, y, STR_NETWORK_GAME_LOBBY_PERFORMANCE); // performance y += FONT_HEIGHT_NORMAL; - for (uint i = 0; i < lengthof(this->company_info[this->company].num_vehicle); i++) { - SetDParam(i, this->company_info[this->company].num_vehicle[i]); - } + SetDParam(0, this->company_info[this->company].num_vehicle[NETWORK_VEH_TRAIN]); + SetDParam(1, this->company_info[this->company].num_vehicle[NETWORK_VEH_LORRY]); + SetDParam(2, this->company_info[this->company].num_vehicle[NETWORK_VEH_BUS]); + SetDParam(3, this->company_info[this->company].num_vehicle[NETWORK_VEH_PLANE]); + SetDParam(4, this->company_info[this->company].num_vehicle[NETWORK_VEH_SHIP]); DrawString(r.left + WD_FRAMERECT_LEFT, r.right - WD_FRAMERECT_RIGHT, y, STR_NETWORK_GAME_LOBBY_VEHICLES); // vehicles y += FONT_HEIGHT_NORMAL; - for (uint i = 0; i < lengthof(this->company_info[this->company].num_station); i++) { - SetDParam(i, this->company_info[this->company].num_station[i]); - } + SetDParam(0, this->company_info[this->company].num_station[NETWORK_VEH_TRAIN]); + SetDParam(1, this->company_info[this->company].num_station[NETWORK_VEH_LORRY]); + SetDParam(2, this->company_info[this->company].num_station[NETWORK_VEH_BUS]); + SetDParam(3, this->company_info[this->company].num_station[NETWORK_VEH_PLANE]); + SetDParam(4, this->company_info[this->company].num_station[NETWORK_VEH_SHIP]); DrawString(r.left + WD_FRAMERECT_LEFT, r.right - WD_FRAMERECT_RIGHT, y, STR_NETWORK_GAME_LOBBY_STATIONS); // stations y += FONT_HEIGHT_NORMAL; -- cgit v1.2.3-54-g00ecf