diff options
author | bjarni <bjarni@openttd.org> | 2006-09-26 19:20:35 +0000 |
---|---|---|
committer | bjarni <bjarni@openttd.org> | 2006-09-26 19:20:35 +0000 |
commit | 1d554da2fc24ab9387d87030b9a3069fcdbfe256 (patch) | |
tree | 8eecbc7c5f192d39d597f64c966f273eb204546b /train.h | |
parent | d9f18c0cbbfba969dddb14a4f8ddb2f9b0102d62 (diff) | |
download | openttd-1d554da2fc24ab9387d87030b9a3069fcdbfe256.tar.xz |
(svn r6515) -Feature: added "start all" and "stop all" buttons to the depot windows
Diffstat (limited to 'train.h')
-rw-r--r-- | train.h | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -218,4 +218,12 @@ static inline Vehicle *GetNextVehicle(const Vehicle *v) void ConvertOldMultiheadToNew(void); void ConnectMultiheadedTrains(void); +static inline bool IsWholeTrainInDepot(const Vehicle *v) +{ + for (; v != NULL; v = v->next) { + if (!(v->vehstatus & VS_HIDDEN)) return false; + } + return true; +} + #endif /* TRAIN_H */ |