Fix incorrect check preventing ordering road vehicles to incompatible depots
This commit is contained in:
@@ -1114,7 +1114,7 @@ static Order GetOrderCmdFromTile(const Vehicle *v, TileIndex tile)
|
||||
|
||||
/* check depot first */
|
||||
if (IsDepotTypeTile(tile, (TransportType)(uint)v->type) && IsInfraTileUsageAllowed(v->type, v->owner, tile)) {
|
||||
if (v->type == VEH_ROAD && ((GetRoadTypes(tile) & RoadVehicle::From(v)->compatible_roadtypes) == 0)) {
|
||||
if (v->type == VEH_ROAD && ((GetPresentRoadTypes(tile) & RoadVehicle::From(v)->compatible_roadtypes) == 0)) {
|
||||
order.Free();
|
||||
return order;
|
||||
}
|
||||
|
Reference in New Issue
Block a user