1 #ifndef __LIGHT_EFFECTS
2 #define __LIGHT_EFFECTS
3 
4 #include "JA2Types.h"
5 
6 
7 // Light effect types
8 enum
9 {
10 	NO_LIGHT_EFFECT,
11 	LIGHT_FLARE_MARK_1,
12 };
13 
14 
15 struct LIGHTEFFECT
16 {
17 	INT16        sGridNo; // gridno at which the tear gas cloud is centered
18 
19 	UINT8        ubDuration; // the number of turns will remain effective
20 	UINT8        bRadius; // the current radius
21 	INT8         bAge; // the number of turns light has been around
22 	BOOLEAN      fAllocated;
23 	INT8         bType;
24 	LIGHT_SPRITE *light;
25 	UINT32       uiTimeOfLastUpdate;
26 };
27 
28 
29 // Decays all light effects...
30 void DecayLightEffects( UINT32 uiTime );
31 
32 LIGHTEFFECT* NewLightEffect(INT16 sGridNo, INT8 bType);
33 
34 
35 void LoadLightEffectsFromLoadGameFile(HWFILE);
36 
37 void SaveLightEffectsToMapTempFile(INT16 sMapX, INT16 sMapY, INT8 bMapZ);
38 void LoadLightEffectsFromMapTempFile(INT16 sMapX, INT16 sMapY, INT8 bMapZ);
39 void ResetLightEffects(void);
40 
41 #endif
42