1
0
mirror of https://github.com/OpenTTD/OpenTTD synced 2026-01-18 09:52:44 +01:00

Codechange: rename CargoID to CargoType and amend related variables/comments

This commit is contained in:
Rubidium
2025-01-22 18:08:59 +01:00
committed by rubidium42
parent d05cc2ef92
commit e894a5880c
129 changed files with 1009 additions and 1009 deletions

View File

@@ -87,7 +87,7 @@ void Order::MakeGoToStation(StationID destination)
* @param action what to do in the depot?
* @param cargo the cargo type to change to.
*/
void Order::MakeGoToDepot(DepotID destination, OrderDepotTypeFlags order, OrderNonStopFlags non_stop_type, OrderDepotActionFlags action, CargoID cargo)
void Order::MakeGoToDepot(DepotID destination, OrderDepotTypeFlags order, OrderNonStopFlags non_stop_type, OrderDepotActionFlags action, CargoType cargo)
{
this->type = OT_GOTO_DEPOT;
this->SetDepotOrderType(order);
@@ -162,7 +162,7 @@ void Order::MakeImplicit(StationID destination)
* @param cargo the cargo type to change to.
* @pre IsType(OT_GOTO_DEPOT) || IsType(OT_GOTO_STATION).
*/
void Order::SetRefit(CargoID cargo)
void Order::SetRefit(CargoType cargo)
{
this->refit_cargo = cargo;
}
@@ -1654,10 +1654,10 @@ CommandCost CmdCloneOrder(DoCommandFlag flags, CloneOptions action, VehicleID ve
* @param flags operation to perform
* @param veh VehicleIndex of the vehicle having the order
* @param order_number number of order to modify
* @param cargo CargoID
* @param cargo CargoType
* @return the cost of this operation or an error
*/
CommandCost CmdOrderRefit(DoCommandFlag flags, VehicleID veh, VehicleOrderID order_number, CargoID cargo)
CommandCost CmdOrderRefit(DoCommandFlag flags, VehicleID veh, VehicleOrderID order_number, CargoType cargo)
{
if (cargo >= NUM_CARGO && cargo != CARGO_NO_REFIT && cargo != CARGO_AUTO_REFIT) return CMD_ERROR;