Changeset - r18042:2032724c55f5
[Not reviewed]
master
0 1 0
frosch - 13 years ago 2011-09-01 19:43:37
frosch@openttd.org
(svn r22867) -Fix (r12122): Variables 40 and 81 of callback 18 are not the same as 80.
1 file changed with 2 insertions and 2 deletions:
0 comments (0 inline, 0 general)
src/newgrf_generic.cpp
Show inline comments
 
@@ -76,28 +76,28 @@ static uint32 GenericCallbackGetTriggers
 
}
 

	
 

	
 
static void GenericCallbackSetTriggers(const ResolverObject *object, int triggers)
 
{
 
	return;
 
}
 

	
 

	
 
static uint32 GenericCallbackGetVariable(const ResolverObject *object, byte variable, byte parameter, bool *available)
 
{
 
	switch (variable) {
 
		case 0x40: return object->u.generic.cargo_type;
 
		case 0x40: return object->grffile->cargo_map[object->u.generic.cargo_type];
 

	
 
		case 0x80: return object->u.generic.cargo_type;
 
		case 0x81: return object->u.generic.cargo_type;
 
		case 0x81: return CargoSpec::Get(object->u.generic.cargo_type)->bitnum;
 
		case 0x82: return object->u.generic.default_selection;
 
		case 0x83: return object->u.generic.src_industry;
 
		case 0x84: return object->u.generic.dst_industry;
 
		case 0x85: return object->u.generic.distance;
 
		case 0x86: return object->u.generic.event;
 
		case 0x87: return object->u.generic.count;
 
		case 0x88: return object->u.generic.station_size;
 

	
 
		default: break;
 
	}
 

	
 
	DEBUG(grf, 1, "Unhandled generic feature variable 0x%02X", variable);
0 comments (0 inline, 0 general)