Mercurial > hg > openttd
changeset 8354:a91ff799f4d5 draft
(svn r11920) -Fix (r11844): train count was incorrect in network lobby window (and 'players' command)
author | glx <glx@openttd.org> |
---|---|
date | Fri, 18 Jan 2008 21:25:18 +0000 |
parents | 6fb24ab5c935 |
children | 73ad124db503 |
files | src/network/network_server.cpp |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/network/network_server.cpp +++ b/src/network/network_server.cpp @@ -1301,7 +1301,7 @@ // Go through all vehicles and count the type of vehicles FOR_ALL_VEHICLES(v) { - if (!IsValidPlayer(v->owner)) continue; + if (!IsValidPlayer(v->owner) || !v->IsPrimaryVehicle()) continue; byte type = 0; switch (v->type) { case VEH_TRAIN: type = 0; break; @@ -1310,7 +1310,7 @@ case VEH_SHIP: type = 4; break; default: continue; } - if (IsEngineCountable(v)) _network_player_info[v->owner].num_vehicle[type]++; + _network_player_info[v->owner].num_vehicle[type]++; } // Go through all stations and count the types of stations