Changeset - r17714:bdfed3434afd
[Not reviewed]
master
0 2 0
frosch - 13 years ago 2011-05-28 09:43:53
frosch@openttd.org
(svn r22504) -Codechange: Add EV_END and use it to check the lengths of _effect_init_procs and _effect_tick_procs.
2 files changed with 3 insertions and 0 deletions:
0 comments (0 inline, 0 general)
src/effectvehicle.cpp
Show inline comments
 
@@ -544,6 +544,7 @@ static EffectInitProc * const _effect_in
 
	BulldozerInit,      // EV_BULLDOZER
 
	BubbleInit,         // EV_BUBBLE
 
};
 
assert_compile(lengthof(_effect_init_procs) == EV_END);
 

	
 
/** Functions for controling effect vehicles at each tick. */
 
static EffectTickProc * const _effect_tick_procs[] = {
 
@@ -558,6 +559,7 @@ static EffectTickProc * const _effect_ti
 
	BulldozerTick,      // EV_BULLDOZER
 
	BubbleTick,         // EV_BUBBLE
 
};
 
assert_compile(lengthof(_effect_tick_procs) == EV_END);
 

	
 

	
 
/**
src/effectvehicle_func.h
Show inline comments
 
@@ -26,6 +26,7 @@ enum EffectVehicleType {
 
	EV_EXPLOSION_SMALL          =  7, ///< Various explosions.
 
	EV_BULLDOZER                =  8, ///< Bulldozer at roadworks.
 
	EV_BUBBLE                   =  9, ///< Bubble of bubble generator (industry).
 
	EV_END
 
};
 

	
 
EffectVehicle *CreateEffectVehicle(int x, int y, int z, EffectVehicleType type);
0 comments (0 inline, 0 general)