@@ -141,16 +141,16 @@ bool LinkRefresher::HandleRefit(CargoID
/**
* Restore capacities and refit_capacities as vehicle might have been able to load now.
*/
void LinkRefresher::ResetRefit()
{
for (RefitList::iterator it(this->refit_capacities.begin()); it != this->refit_capacities.end(); ++it) {
if (it->remaining == it->capacity) continue;
this->capacities[it->cargo] += it->capacity - it->remaining;
it->remaining = it->capacity;
for (auto &it : this->refit_capacities) {
if (it.remaining == it.capacity) continue;
this->capacities[it.cargo] += it.capacity - it.remaining;
it.remaining = it.capacity;
}
* Predict the next order the vehicle will execute and resolve conditionals by
* recursion and return next non-conditional order in list.