From 3867a70dd879e8c1225ae883b2be0946332a3982 Mon Sep 17 00:00:00 2001 From: MysterD Date: Mon, 24 Apr 2023 01:18:33 -0700 Subject: [PATCH] Fixed crash in bhv_chain_chomp_gate_update() --- src/game/behaviors/chain_chomp.inc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/game/behaviors/chain_chomp.inc.c b/src/game/behaviors/chain_chomp.inc.c index 0f8177a6..9fb582b6 100644 --- a/src/game/behaviors/chain_chomp.inc.c +++ b/src/game/behaviors/chain_chomp.inc.c @@ -558,7 +558,7 @@ void bhv_chain_chomp_gate_init(void) { * Update function for chain chomp gate */ void bhv_chain_chomp_gate_update(void) { - if (o->parentObj && o->parentObj->oChainChompHitGate) { + if (o && o->parentObj && o->parentObj->oChainChompHitGate) { spawn_mist_particles_with_sound(SOUND_GENERAL_WALL_EXPLOSION); set_camera_shake_from_point(SHAKE_POS_SMALL, o->oPosX, o->oPosY, o->oPosZ); spawn_mist_particles_variable(0, 0x7F, 200.0f);