summaryrefslogtreecommitdiff
path: root/src/depot.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/depot.cpp')
-rw-r--r--src/depot.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/depot.cpp b/src/depot.cpp
index f53a51ff0..039ab5b34 100644
--- a/src/depot.cpp
+++ b/src/depot.cpp
@@ -27,12 +27,14 @@ Depot::~Depot()
{
if (CleaningPool()) return;
+ /* Clear the order backup. */
+ OrderBackup::Reset(this->xy, false);
+
/* Clear the depot from all order-lists */
RemoveOrderFromAllVehicles(OT_GOTO_DEPOT, this->index);
/* Delete the depot-window */
DeleteWindowById(WC_VEHICLE_DEPOT, this->xy);
- OrderBackup::Reset(this->xy);
/* Delete the depot list */
WindowNumber wno = (this->index << 16) | VLW_DEPOT_LIST | GetTileOwner(this->xy);