diff options
author | rubidium <rubidium@openttd.org> | 2009-01-10 09:51:14 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2009-01-10 09:51:14 +0000 |
commit | 3d6c09b38d54da55ba7688fab8acb5879a34c861 (patch) | |
tree | c150281da19ec8c75bcae7d7526de3017ee154db /src/aircraft.h | |
parent | ece7d9a16f66102aa2b384c45c13dc2a31cce7f8 (diff) | |
download | openttd-3d6c09b38d54da55ba7688fab8acb5879a34c861.tar.xz |
(svn r14952) -Codechange: unify the "can vehicle go to station" tests
Diffstat (limited to 'src/aircraft.h')
-rw-r--r-- | src/aircraft.h | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/src/aircraft.h b/src/aircraft.h index b5a231e25..faf888f88 100644 --- a/src/aircraft.h +++ b/src/aircraft.h @@ -34,29 +34,6 @@ static inline bool IsNormalAircraft(const Vehicle *v) return v->subtype <= AIR_AIRCRAFT; } -/** Checks if an aircraft can use the station in question - * @param engine The engine to test - * @param st The station - * @return true if the aircraft can use the station - */ -static inline bool CanAircraftUseStation(EngineID engine, const Station *st) -{ - const AirportFTAClass *apc = st->Airport(); - const AircraftVehicleInfo *avi = AircraftVehInfo(engine); - - return (apc->flags & (avi->subtype & AIR_CTOL ? AirportFTAClass::AIRPLANES : AirportFTAClass::HELICOPTERS)) != 0; -} - -/** Checks if an aircraft can use the station at the tile in question - * @param engine The engine to test - * @param tile The tile where the station is - * @return true if the aircraft can use the station - */ -static inline bool CanAircraftUseStation(EngineID engine, TileIndex tile) -{ - return CanAircraftUseStation(engine, GetStationByTile(tile)); -} - /** * Calculates cargo capacity based on an aircraft's passenger * and mail capacities. |