summaryrefslogtreecommitdiffstats
path: root/src/render/2dEffect.h
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2019-06-17 10:30:02 +0200
committeraap <aap@papnet.eu>2019-06-17 22:40:15 +0200
commitb5fba778c4a307f0a5721c9b3b0efb38be96634b (patch)
tree9fe0738d1d6dcf4677aac12e1efadff18887f7b4 /src/render/2dEffect.h
parentMerge pull request #20 from gennariarmando/master (diff)
downloadre3-b5fba778c4a307f0a5721c9b3b0efb38be96634b.tar
re3-b5fba778c4a307f0a5721c9b3b0efb38be96634b.tar.gz
re3-b5fba778c4a307f0a5721c9b3b0efb38be96634b.tar.bz2
re3-b5fba778c4a307f0a5721c9b3b0efb38be96634b.tar.lz
re3-b5fba778c4a307f0a5721c9b3b0efb38be96634b.tar.xz
re3-b5fba778c4a307f0a5721c9b3b0efb38be96634b.tar.zst
re3-b5fba778c4a307f0a5721c9b3b0efb38be96634b.zip
Diffstat (limited to 'src/render/2dEffect.h')
-rw-r--r--src/render/2dEffect.h28
1 files changed, 21 insertions, 7 deletions
diff --git a/src/render/2dEffect.h b/src/render/2dEffect.h
index 6cba85d1..780d9b4f 100644
--- a/src/render/2dEffect.h
+++ b/src/render/2dEffect.h
@@ -1,3 +1,9 @@
+enum {
+ EFFECT_LIGHT,
+ EFFECT_PARTICLE,
+ EFFECT_ATTRACTOR
+};
+
class C2dEffect
{
public:
@@ -7,26 +13,26 @@ public:
float size;
float innerRange;
uint8 flash;
- uint8 wet;
- uint8 flare;
- uint8 shadowIntens;
- uint8 flag;
+ uint8 roadReflection;
+ uint8 flareType;
+ uint8 shadowIntensity;
+ uint8 flags;
RwTexture *corona;
RwTexture *shadow;
};
struct Particle {
int particleType;
- float dir[3];
+ CVector dir;
float scale;
};
struct Attractor {
CVector dir;
- uint8 flag;
+ uint8 flags;
uint8 probability;
};
CVector pos;
- RwRGBA col;
+ CRGBA col;
uint8 type;
union {
Light light;
@@ -35,5 +41,13 @@ public:
};
C2dEffect(void) {}
+ void Shutdown(void){
+ if(type == 0){ // TODO: enum
+ if(light.corona)
+ RwTextureDestroy(light.corona);
+ if(light.shadow)
+ RwTextureDestroy(light.shadow);
+ }
+ }
};
static_assert(sizeof(C2dEffect) == 0x34, "C2dEffect: error");