mirror of
https://github.com/JGRennison/OpenTTD-patches.git
synced 2024-11-11 13:10:45 +00:00
Through load: Show vehicle advice message if ignored due to rear in depot
This commit is contained in:
parent
4d514f3b19
commit
17a5b7e9a9
@ -1993,6 +1993,13 @@ static void LoadUnloadVehicle(Vehicle *front)
|
||||
/* Disallow through-load when any part of train is in a depot, to prevent cheating */
|
||||
if (Train::From(v)->IsInDepot()) {
|
||||
pull_through_mode = false;
|
||||
if (_local_company == v->owner) {
|
||||
SetDParam(0, front->index);
|
||||
SetDParam(1, order->GetDestination());
|
||||
AddNewsItem(STR_VEHICLE_LOAD_THROUGH_ABORTED_DEPOT, NT_ADVICE, NF_INCOLOUR | NF_SMALL | NF_VEHICLE_PARAM0,
|
||||
NR_VEHICLE, front->index,
|
||||
NR_STATION, order->GetDestination());
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user