summaryrefslogtreecommitdiff
path: root/src/network
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2009-12-02 17:37:02 +0000
committerfrosch <frosch@openttd.org>2009-12-02 17:37:02 +0000
commit59f9163e37a7da7e8ef1cf52de8aa5e349ead5c1 (patch)
tree2119cf742c992f2df8b00ca09365f722679628d9 /src/network
parent2265202d7764d861fd3f85d10fd550cf39ba2037 (diff)
downloadopenttd-59f9163e37a7da7e8ef1cf52de8aa5e349ead5c1.tar.xz
(svn r18381) -Codechange: Add RoadVehicle::IsBus() to simplify some stuff.
Diffstat (limited to 'src/network')
-rw-r--r--src/network/network_server.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/network/network_server.cpp b/src/network/network_server.cpp
index 641de9109..82e8de6a4 100644
--- a/src/network/network_server.cpp
+++ b/src/network/network_server.cpp
@@ -28,7 +28,7 @@
#include "../company_func.h"
#include "../company_gui.h"
#include "../window_func.h"
-#include "../cargotype.h"
+#include "../roadveh.h"
#include "table/strings.h"
@@ -1368,7 +1368,7 @@ void NetworkPopulateCompanyStats(NetworkCompanyStats *stats)
byte type = 0;
switch (v->type) {
case VEH_TRAIN: type = 0; break;
- case VEH_ROAD: type = IsCargoInClass(v->cargo_type, CC_PASSENGERS) ? 2 : 1; break;
+ case VEH_ROAD: type = RoadVehicle::From(v)->IsBus() ? 2 : 1; break;
case VEH_AIRCRAFT: type = 3; break;
case VEH_SHIP: type = 4; break;
default: continue;