diff options
author | yexo <yexo@openttd.org> | 2010-03-19 09:48:44 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2010-03-19 09:48:44 +0000 |
commit | 414071d07f787042364fec573030720ba664154e (patch) | |
tree | 57593a3df5182caf905c03c7f99b0ac8802048ce /src/station_base.h | |
parent | 81ca0e28c4504bbc7828df50b2086bbdb8776dd1 (diff) | |
download | openttd-414071d07f787042364fec573030720ba664154e.tar.xz |
(svn r19463) -Codechange: add helper function to determine if an airport has at least one hangar
Diffstat (limited to 'src/station_base.h')
-rw-r--r-- | src/station_base.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/station_base.h b/src/station_base.h index adb58cc89..f15a5dabd 100644 --- a/src/station_base.h +++ b/src/station_base.h @@ -62,6 +62,11 @@ struct Airport : public TileArea { { return this->GetSpec()->fsm; } + + FORCEINLINE bool HasHangar() const + { + return this->GetSpec()->nof_depots > 0; + } }; typedef SmallVector<Industry *, 2> IndustryVector; |