summaryrefslogtreecommitdiff
path: root/station_cmd.c
diff options
context:
space:
mode:
authortron <tron@openttd.org>2006-09-03 10:30:38 +0000
committertron <tron@openttd.org>2006-09-03 10:30:38 +0000
commit23168f630952490f6a548f1889e1a3b035b29f1d (patch)
treed1fcc0253686a550d7bd5beecb23ae1975b0e2f2 /station_cmd.c
parent1c21c645ae04601cd3711b37e6541d807cb727a7 (diff)
downloadopenttd-23168f630952490f6a548f1889e1a3b035b29f1d.tar.xz
(svn r6355) -Fix: Go to hangar orders for aircraft could get spuriously removed when a road or rail depot got deleted (Darkvater and me)
This bug is probably ages old
Diffstat (limited to 'station_cmd.c')
-rw-r--r--station_cmd.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/station_cmd.c b/station_cmd.c
index 1b71bdd85..0acc48864 100644
--- a/station_cmd.c
+++ b/station_cmd.c
@@ -2376,7 +2376,6 @@ void DestroyRoadStop(RoadStop* rs)
void DestroyStation(Station *st)
{
StationID index;
- Vehicle *v;
index = st->index;
@@ -2390,23 +2389,6 @@ void DestroyStation(Station *st)
/* Now delete all orders that go to the station */
RemoveOrderFromAllVehicles(OT_GOTO_STATION, index);
- //And do the same with aircraft that have the station as a hangar-stop
- FOR_ALL_VEHICLES(v) {
- bool invalidate = false;
- if (v->type == VEH_Aircraft) {
- Order *order;
- FOR_VEHICLE_ORDERS(v, order) {
- if (order->type == OT_GOTO_DEPOT && order->dest == index) {
- order->type = OT_DUMMY;
- order->flags = 0;
- invalidate = true;
- }
- }
- }
- //Orders for the vehicle have been changed, invalidate the window
- if (invalidate) InvalidateWindow(WC_VEHICLE_ORDERS, v->index);
- }
-
//Subsidies need removal as well
DeleteSubsidyWithStation(index);