summaryrefslogtreecommitdiff
path: root/src/network
diff options
context:
space:
mode:
authorDarkvater <darkvater@openttd.org>2007-01-27 12:29:55 +0000
committerDarkvater <darkvater@openttd.org>2007-01-27 12:29:55 +0000
commit50ca901b40664453fe90a396577e6438fd45dc27 (patch)
treec85d1c112d4c04fb8079a90418ad3b654765dff3 /src/network
parent8bebb83de97756e1781c418dc1fcc021fad483db (diff)
downloadopenttd-50ca901b40664453fe90a396577e6438fd45dc27.tar.xz
(svn r8428) -Codechange: Add proper names to aircraft subtypes instead of magic numbers and add a function IsNormalAircraft() which tells us whether the aircraft is in fact some flying device or a rotor/shadow.
Diffstat (limited to 'src/network')
-rw-r--r--src/network/network_server.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/network/network_server.cpp b/src/network/network_server.cpp
index 612a9edef..f69340afd 100644
--- a/src/network/network_server.cpp
+++ b/src/network/network_server.cpp
@@ -10,6 +10,7 @@
#include "network_data.h"
#include "core/tcp.h"
#include "../train.h"
+#include "../aircraft.h"
#include "../date.h"
#include "table/strings.h"
#include "../functions.h"
@@ -1255,7 +1256,7 @@ void NetworkPopulateCompanyInfo(void)
break;
case VEH_Aircraft:
- if (v->subtype <= 2) _network_player_info[v->owner].num_vehicle[3]++;
+ if (IsNormalAircraft(v)) _network_player_info[v->owner].num_vehicle[3]++;
break;
case VEH_Ship: