Changeset - r19751:03c8fbcaf14c
[Not reviewed]
master
0 1 0
frosch - 12 years ago 2012-11-12 18:10:42
frosch@openttd.org
(svn r24706) -Fix (r10981): [NewGRF] Station var 48 should report acceptance, not supply.
1 file changed with 1 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/newgrf_station.cpp
Show inline comments
 
@@ -391,13 +391,13 @@ uint32 Station::GetNewGRFVariable(const 
 
	switch (variable) {
 
		case 0x48: { // Accepted cargo types
 
			CargoID cargo_type;
 
			uint32 value = 0;
 

	
 
			for (cargo_type = 0; cargo_type < NUM_CARGO; cargo_type++) {
 
				if (HasBit(this->goods[cargo_type].acceptance_pickup, GoodsEntry::GES_PICKUP)) SetBit(value, cargo_type);
 
				if (HasBit(this->goods[cargo_type].acceptance_pickup, GoodsEntry::GES_ACCEPTANCE)) SetBit(value, cargo_type);
 
			}
 
			return value;
 
		}
 

	
 
		case 0x8A: return this->had_vehicle_of_type;
 
		case 0xF1: return (this->airport.tile != INVALID_TILE) ? this->airport.GetSpec()->ttd_airport_type : ATP_TTDP_LARGE;
0 comments (0 inline, 0 general)