From 4b153385364a82f5b63c3d385cd323201ddd12dd Mon Sep 17 00:00:00 2001 From: MysterD Date: Wed, 4 May 2022 05:50:30 -0700 Subject: [PATCH 1/3] Another possible fix for snow crash --- src/game/envfx_snow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/game/envfx_snow.c b/src/game/envfx_snow.c index 85b5e9f0e..93eff5ff4 100644 --- a/src/game/envfx_snow.c +++ b/src/game/envfx_snow.c @@ -431,7 +431,7 @@ Gfx *envfx_update_snow_internal(s32 snowMode, Vec3s marioPos, Vec3s camFrom, Vec s16 radius, pitch, yaw; Vec3s snowCylinderPos; struct SnowFlakeVertex vertex1, vertex2, vertex3; - Gfx *gfxStart; + Gfx *gfxStart = NULL; Gfx *gfx; vertex1 = gSnowFlakeVertex1; From 0b33a2696041443555bab6b0ceec9db3225da051 Mon Sep 17 00:00:00 2001 From: MysterD Date: Wed, 4 May 2022 06:00:46 -0700 Subject: [PATCH 2/3] Possible fix for crash handler --- src/pc/crash_handler.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/pc/crash_handler.c b/src/pc/crash_handler.c index 82c51ab2d..dae4b77fd 100644 --- a/src/pc/crash_handler.c +++ b/src/pc/crash_handler.c @@ -120,6 +120,9 @@ void render_create_dl_ortho_matrix() { } static void crash_handler_produce_one_frame() { + extern u8 gRenderingInterpolated; + gRenderingInterpolated = false; + // Start frame gfx_start_frame(); load_gfx_memory_pool(); From 2e57e001d47040c07aef8f6931f9c09cc648d6d1 Mon Sep 17 00:00:00 2001 From: MysterD Date: Wed, 4 May 2022 06:26:40 -0700 Subject: [PATCH 3/3] Another snow crash fix --- src/game/envfx_snow.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/game/envfx_snow.c b/src/game/envfx_snow.c index 93eff5ff4..f48cd90dc 100644 --- a/src/game/envfx_snow.c +++ b/src/game/envfx_snow.c @@ -455,7 +455,9 @@ Gfx *envfx_update_snow_internal(s32 snowMode, Vec3s marioPos, Vec3s camFrom, Vec return NULL; } - envfx_update_snowflake_count(snowMode, marioPos); + if (!interpolated) { + envfx_update_snowflake_count(snowMode, marioPos); + } // Note: to and from are inverted here, so the resulting vector goes towards the camera orbit_from_positions(camTo, camFrom, &radius, &pitch, &yaw);