From 9f6c37c1fd64418fc84059c433dfb3ee3bbb788e Mon Sep 17 00:00:00 2001 From: En Yi Date: Sun, 11 Aug 2024 15:50:11 +0800 Subject: [PATCH] Fix bubbling particles issue out-of-water --- scenes/game_systems.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scenes/game_systems.c b/scenes/game_systems.c index 32a14d3..3d3be6a 100644 --- a/scenes/game_systems.c +++ b/scenes/game_systems.c @@ -1847,6 +1847,14 @@ void airtimer_update_system(Scene_t* scene) { p_air->curr_count = p_air->max_count; p_air->curr_ftimer = p_air->max_ftimer * 2; // Lengthen the first + CEmitter_t* p_emitter = get_component(p_ent, CEMITTER_T); + if (p_emitter != NULL) + { + if (is_emitter_handle_alive(&scene->part_sys, p_emitter->handle)) + { + unload_emitter_handle(&scene->part_sys, p_emitter->handle); + } + } } else {