Codechange: remove loaded_at_xy from CargoPacket as it was unused (#11276)

This commit is contained in:
Patric Stout
2023-09-09 21:24:46 +02:00
committed by GitHub
parent f3b4f9d640
commit b0e73277d6
13 changed files with 24 additions and 83 deletions

View File

@@ -1469,7 +1469,7 @@ struct FinalizeRefitAction
{
if (this->do_reserve) {
this->st->goods[v->cargo_type].cargo.Reserve(v->cargo_cap - v->cargo.RemainingCount(),
&v->cargo, st->xy, this->next_station);
&v->cargo, this->next_station);
}
this->consist_capleft[v->cargo_type] += v->cargo_cap - v->cargo.RemainingCount();
return true;
@@ -1560,7 +1560,7 @@ struct ReserveCargoAction {
{
if (v->cargo_cap > v->cargo.RemainingCount() && MayLoadUnderExclusiveRights(st, v)) {
st->goods[v->cargo_type].cargo.Reserve(v->cargo_cap - v->cargo.RemainingCount(),
&v->cargo, st->xy, *next_station);
&v->cargo, *next_station);
}
return true;
@@ -1791,7 +1791,7 @@ static void LoadUnloadVehicle(Vehicle *front)
if (v->cargo.StoredCount() == 0) TriggerVehicle(v, VEHICLE_TRIGGER_NEW_CARGO);
if (_settings_game.order.gradual_loading) cap_left = std::min(cap_left, GetLoadAmount(v));
uint loaded = ge->cargo.Load(cap_left, &v->cargo, st->xy, next_station);
uint loaded = ge->cargo.Load(cap_left, &v->cargo, next_station);
if (v->cargo.ActionCount(VehicleCargoList::MTA_LOAD) > 0) {
/* Remember if there are reservations left so that we don't stop
* loading before they're loaded. */