diff options
author | tron <tron@openttd.org> | 2007-02-03 13:03:11 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2007-02-03 13:03:11 +0000 |
commit | f0f86442ad34b1ffffd59e31077c656e03f7ad70 (patch) | |
tree | f379d9c86409257099d882453dc9dafc2fd07f67 /src/airport.h | |
parent | 19c981b19ef25fb75cfb0a3e2966e5118673dd23 (diff) | |
download | openttd-f0f86442ad34b1ffffd59e31077c656e03f7ad70.tar.xz |
(svn r8559) -Fix
-Codechange: Put the airport movement data into struct AirportFTAClass
Diffstat (limited to 'src/airport.h')
-rw-r--r-- | src/airport.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/airport.h b/src/airport.h index 75c275e2d..a020b14ef 100644 --- a/src/airport.h +++ b/src/airport.h @@ -130,6 +130,14 @@ typedef struct AirportMovingData { // Finite sTate mAchine --> FTA typedef struct AirportFTAClass { + public: + const AirportMovingData *MovingData(byte position) const + { + assert(position < nofelements); + return &moving_data[position]; + } + + const AirportMovingData *moving_data; byte nofelements; // number of positions the airport consists of const byte *terminals; const byte *helipads; @@ -154,7 +162,6 @@ typedef struct AirportFTA { void InitializeAirports(void); void UnInitializeAirports(void); const AirportFTAClass *GetAirport(const byte airport_type); -const AirportMovingData *GetAirportMovingData(byte airport_type, byte position); /** Get buildable airport bitmask. * @return get all buildable airports at this given time, bitmasked. |