@@ -26,24 +26,24 @@ struct Depot : DepotPool::PoolItem<&_dep
uint16 town_cn; ///< The N-1th depot for this town (consecutive number)
Date build_date; ///< Date of construction
Depot(TileIndex xy = INVALID_TILE) : xy(xy) {}
~Depot();
static FORCEINLINE Depot *GetByTile(TileIndex tile)
static inline Depot *GetByTile(TileIndex tile)
{
return Depot::Get(GetDepotIndex(tile));
}
/**
* Is the "type" of depot the same as the given depot,
* i.e. are both a rail, road or ship depots?
* @param d The depot to compare to.
* @return true iff their types are equal.
*/
FORCEINLINE bool IsOfType(const Depot *d) const
inline bool IsOfType(const Depot *d) const
return GetTileType(d->xy) == GetTileType(this->xy);
};
#define FOR_ALL_DEPOTS_FROM(var, start) FOR_ALL_ITEMS_FROM(Depot, depot_index, var, start)