mirror of https://github.com/OpenTTD/OpenTTD
Change: Modify IsChainInDepot for ground vehicles.
parent
d489e22cfb
commit
421a533fbb
|
@ -197,7 +197,10 @@ bool GroundVehicle<T, Type>::IsChainInDepot() const
|
||||||
|
|
||||||
/* Check whether the rest is also already trying to enter the depot. */
|
/* Check whether the rest is also already trying to enter the depot. */
|
||||||
for (; v != nullptr; v = v->Next()) {
|
for (; v != nullptr; v = v->Next()) {
|
||||||
if (!v->T::IsInDepot() || v->tile != this->tile) return false;
|
if (!v->T::IsInDepot()) return false;
|
||||||
|
assert(IsDepotTile(v->tile));
|
||||||
|
assert(IsDepotTile(this->tile));
|
||||||
|
assert(GetDepotIndex(this->tile) == GetDepotIndex(v->tile));
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in New Issue