(svn r12791) -Codechange: [autoreplace] Added a flag parameter (listens for DC_EXEC and DC_QUERY_COST) and included more info when returning CommandCost

This allowed cleaning up the code in MaybeReplaceVehicle()
This commit is contained in:
bjarni
2008-04-19 15:14:20 +00:00
parent 752c8d8f2e
commit ad3ef0fb26
3 changed files with 106 additions and 73 deletions

View File

@@ -71,7 +71,7 @@ void BuildDepotVehicleList(VehicleType type, TileIndex tile, Vehicle ***engine_l
CommandCost SendAllVehiclesToDepot(VehicleType type, uint32 flags, bool service, PlayerID owner, uint16 vlw_flag, uint32 id);
void VehicleEnterDepot(Vehicle *v);
CommandCost MaybeReplaceVehicle(Vehicle *v, bool check, bool display_costs);
CommandCost MaybeReplaceVehicle(Vehicle *v, uint32 flags, bool display_costs);
bool CanBuildVehicleInfrastructure(VehicleType type);
void CcCloneVehicle(bool success, TileIndex tile, uint32 p1, uint32 p2);