(svn r27584) -Codechange: Add some assertions about Vehicle::cargo_payment.

This commit is contained in:
frosch
2016-05-29 13:33:20 +00:00
parent 7d4754a4f8
commit dac94c7cbc
2 changed files with 4 additions and 1 deletions

View File

@@ -1651,6 +1651,7 @@ static void LoadUnloadVehicle(Vehicle *front)
uint amount_unloaded = _settings_game.order.gradual_loading ? min(cargo_count, load_amount) : cargo_count;
bool remaining = false; // Are there cargo entities in this vehicle that can still be unloaded here?
assert(payment != NULL);
payment->SetCargo(v->cargo_type);
if (!HasBit(ge->status, GoodsEntry::GES_ACCEPTANCE) && v->cargo.ActionCount(VehicleCargoList::MTA_DELIVER) > 0) {