1
0
mirror of https://github.com/OpenTTD/OpenTTD synced 2026-01-16 08:52:40 +01:00

(svn r25185) -Fix [FS#5508]: Remove ambivalent functions CargoList::Empty() and Count(), and replace them with VehicleCargoList::StoredCount(), TotalCount(), StationCargoList::AvailableCount() and TotalCount(). (fonsinchen)

This commit is contained in:
frosch
2013-04-13 13:42:08 +00:00
parent 8d1d521456
commit 5eddbb338b
20 changed files with 105 additions and 82 deletions

View File

@@ -399,7 +399,7 @@
uint32 amount = 0;
for (const Vehicle *v = ::Vehicle::Get(vehicle_id); v != NULL; v = v->Next()) {
if (v->cargo_type == cargo) amount += v->cargo.Count();
if (v->cargo_type == cargo) amount += v->cargo.StoredCount();
}
return amount;