1
0
Fork 0
mirror of https://github.com/halpz/re3.git synced 2024-12-25 18:05:27 +00:00

fix crash on exit

This commit is contained in:
Fire-Head 2021-01-17 03:13:21 +03:00
parent 6075bf3fc2
commit f5164f3804
2 changed files with 12 additions and 3 deletions

View file

@ -1108,6 +1108,7 @@ CVehicleModelInfo::SetEnvironmentMapCB(RpAtomic *atomic, void *data)
void void
CVehicleModelInfo::SetEnvironmentMap(void) CVehicleModelInfo::SetEnvironmentMap(void)
{ {
/*
CSimpleModelInfo *wheelmi; CSimpleModelInfo *wheelmi;
int32 i; int32 i;
@ -1125,6 +1126,7 @@ CVehicleModelInfo::SetEnvironmentMap(void)
for(i = 0; i < wheelmi->m_numAtomics; i++) for(i = 0; i < wheelmi->m_numAtomics; i++)
SetEnvironmentMapCB(wheelmi->m_atomics[i], nil); SetEnvironmentMapCB(wheelmi->m_atomics[i], nil);
} }
*/
#ifdef EXTENDED_PIPELINES #ifdef EXTENDED_PIPELINES
CustomPipes::AttachVehiclePipe(m_clump); CustomPipes::AttachVehiclePipe(m_clump);
@ -1150,10 +1152,12 @@ CVehicleModelInfo::LoadEnvironmentMaps(void)
void void
CVehicleModelInfo::ShutdownEnvironmentMaps(void) CVehicleModelInfo::ShutdownEnvironmentMaps(void)
{ {
/*
RwTextureDestroy(gpWhiteTexture); RwTextureDestroy(gpWhiteTexture);
gpWhiteTexture = nil; gpWhiteTexture = nil;
RwFrameDestroy(pMatFxIdentityFrame); RwFrameDestroy(pMatFxIdentityFrame);
pMatFxIdentityFrame = nil; pMatFxIdentityFrame = nil;
*/
} }
int int

View file

@ -905,8 +905,13 @@ void CParticle::Shutdown()
RwTextureDestroy(gpRainDripTex[i]); RwTextureDestroy(gpRainDripTex[i]);
gpRainDripTex[i] = nil; gpRainDripTex[i] = nil;
RwTextureDestroy(gpRainDripDarkTex[i]); // hmm, i think gpRainDripDarkTex[1(one)] can crash, let's wait for report hehe #ifdef FIX_BUGS
gpRainDripDarkTex[i] = nil; if (gpRainDripDarkTex[i])
#endif
{
RwTextureDestroy(gpRainDripDarkTex[i]);
gpRainDripDarkTex[i] = nil;
}
} }
RwTextureDestroy(gpBoatWakeTex); RwTextureDestroy(gpBoatWakeTex);