Add current order (station, waypoint or depot) condition variable.
Adjust item bit allocations: * Increase cond flags from 2 bits to 3 bits, for future expansion. * Use 2 bits remaining in adjacent gap for an auxiliary type field. This is used for the type (station, waypoint, etc.) of order tests. Perform a linear scan of the program pool when deleting a station, waypoint or depot.
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
#include "window_func.h"
|
||||
#include "newgrf_station.h"
|
||||
#include "waypoint_base.h"
|
||||
#include "tracerestrict.h"
|
||||
|
||||
#include "safeguards.h"
|
||||
|
||||
@@ -54,4 +55,5 @@ Waypoint::~Waypoint()
|
||||
if (CleaningPool()) return;
|
||||
DeleteWindowById(WC_WAYPOINT_VIEW, this->index);
|
||||
RemoveOrderFromAllVehicles(OT_GOTO_WAYPOINT, this->index);
|
||||
TraceRestrictRemoveDestinationID(TROCAF_WAYPOINT, this->index);
|
||||
}
|
||||
|
Reference in New Issue
Block a user