summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFire-Head <Fire-Head@users.noreply.github.com>2021-02-15 19:25:18 +0100
committerFire-Head <Fire-Head@users.noreply.github.com>2021-02-15 19:25:18 +0100
commit63e5afda0b569903b59f46192294f1c1c240c6f8 (patch)
tree169abf8bcd13a8464f7f4a0921f33b1463429576
parentremoved some f suffixes from shaders (diff)
downloadre3-63e5afda0b569903b59f46192294f1c1c240c6f8.tar
re3-63e5afda0b569903b59f46192294f1c1c240c6f8.tar.gz
re3-63e5afda0b569903b59f46192294f1c1c240c6f8.tar.bz2
re3-63e5afda0b569903b59f46192294f1c1c240c6f8.tar.lz
re3-63e5afda0b569903b59f46192294f1c1c240c6f8.tar.xz
re3-63e5afda0b569903b59f46192294f1c1c240c6f8.tar.zst
re3-63e5afda0b569903b59f46192294f1c1c240c6f8.zip
-rw-r--r--src/render/Particle.cpp27
1 files changed, 13 insertions, 14 deletions
diff --git a/src/render/Particle.cpp b/src/render/Particle.cpp
index 51249844..8c9cde12 100644
--- a/src/render/Particle.cpp
+++ b/src/render/Particle.cpp
@@ -49,6 +49,8 @@
#define MAX_RAINDRIP_FILES (2)
+#define MAX_LEAF_FILES (2)
+
const char SmokeFiles[][6+1] =
{
@@ -165,7 +167,7 @@ RwTexture *gpFlame1Tex;
RwTexture *gpFlame5Tex;
RwTexture *gpRainDropSmallTex;
RwTexture *gpBloodTex;
-RwTexture *gpLeafTex;
+RwTexture *gpLeafTex[MAX_LEAF_FILES];
RwTexture *gpCloudTex1;
RwTexture *gpCloudTex4;
RwTexture *gpBloodSmallTex;
@@ -193,7 +195,7 @@ RwRaster *gpFlame1Raster;
RwRaster *gpFlame5Raster;
RwRaster *gpRainDropSmallRaster;
RwRaster *gpBloodRaster;
-RwRaster *gpLeafRaster;
+RwRaster *gpLeafRaster[MAX_LEAF_FILES];
RwRaster *gpCloudRaster1;
RwRaster *gpCloudRaster4;
RwRaster *gpBloodSmallRaster;
@@ -206,9 +208,6 @@ RwRaster *gpPointlightRaster;
RwTexture *gpRainDropTex;
RwRaster *gpRainDropRaster;
-RwTexture *gpLetterTex;
-RwRaster *gpLetterRaster;
-
RwTexture *gpSparkTex;
RwTexture *gpNewspaperTex;
RwTexture *gpGunSmokeTex;
@@ -425,11 +424,11 @@ void CParticle::Initialise()
gpBloodTex = RwTextureRead("blood", nil);
gpBloodRaster = RwTextureGetRaster(gpBloodTex);
- gpLeafTex = RwTextureRead("gameleaf01_64", nil);
- gpLeafRaster = RwTextureGetRaster(gpLeafTex);
+ gpLeafTex[0] = RwTextureRead("gameleaf01_64", nil);
+ gpLeafRaster[0] = RwTextureGetRaster(gpLeafTex[0]);
- gpLetterTex = RwTextureRead("letter", nil);
- gpLetterRaster = RwTextureGetRaster(gpLetterTex);
+ gpLeafTex[1] = RwTextureRead("letter", nil);
+ gpLeafRaster[1] = RwTextureGetRaster(gpLeafTex[1]);
gpCloudTex1 = RwTextureRead("cloud3", nil);
gpCloudRaster1 = RwTextureGetRaster(gpCloudTex1);
@@ -543,7 +542,7 @@ void CParticle::Initialise()
case PARTICLE_DEBRIS:
case PARTICLE_TREE_LEAVES:
- entry->m_ppRaster = &gpLeafRaster;
+ entry->m_ppRaster = gpLeafRaster;
break;
case PARTICLE_DEBRIS2:
@@ -773,11 +772,11 @@ void CParticle::Shutdown()
RwTextureDestroy(gpBloodTex);
gpBloodTex = nil;
- RwTextureDestroy(gpLeafTex);
- gpLeafTex = nil;
+ RwTextureDestroy(gpLeafTex[0]);
+ gpLeafTex[0] = nil;
- RwTextureDestroy(gpLetterTex);
- gpLetterTex = nil;
+ RwTextureDestroy(gpLeafTex[1]);
+ gpLeafTex[1] = nil;
RwTextureDestroy(gpCloudTex1);
gpCloudTex1 = nil;