diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/newgrf_engine.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/newgrf_engine.cpp b/src/newgrf_engine.cpp index 97dd90ca9..908d15a84 100644 --- a/src/newgrf_engine.cpp +++ b/src/newgrf_engine.cpp @@ -23,6 +23,7 @@ #include "station_base.h" #include "company_base.h" #include "newgrf_railtype.h" +#include "ship.h" struct WagonOverride { EngineID *train_id; @@ -834,6 +835,14 @@ static uint32 VehicleGetVariable(Vehicle *v, const ResolverObject *object, byte break; } + case VEH_SHIP: { + Ship *s = Ship::From(v); + switch (variable - 0x80) { + case 0x62: return s->state; + } + break; + } + case VEH_AIRCRAFT: { Aircraft *a = Aircraft::From(v); switch (variable - 0x80) { |