From 49be9d159b8d9e905755fd8eaa32230668f1fcb7 Mon Sep 17 00:00:00 2001 From: xLuigiGamerx <88401287+xLuigiGamerx@users.noreply.github.com> Date: Tue, 24 Sep 2024 03:04:50 +0300 Subject: [PATCH] Allowed Dynos to use geo_mario_cap_display_list (#337) * Allowed Dynos to use geo_mario_cap_display_list * Fixed [CS] Extra Characters breaking voices in other CS mods --- data/dynos_mgr_builtin.cpp | 1 + mods/char-select-extra-chars/z-voices.lua | 12 ++++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/data/dynos_mgr_builtin.cpp b/data/dynos_mgr_builtin.cpp index e4a836e37..96fb22fea 100644 --- a/data/dynos_mgr_builtin.cpp +++ b/data/dynos_mgr_builtin.cpp @@ -1398,6 +1398,7 @@ static const void* sDynosBuiltinFuncs[] = { define_builtin(geo_movtex_draw_water_regions_ext), define_builtin(lvl_init_or_update), define_builtin(geo_choose_area_ext), + define_builtin(geo_mario_cap_display_list), // Behaviors define_builtin(bhv_cap_switch_loop), diff --git a/mods/char-select-extra-chars/z-voices.lua b/mods/char-select-extra-chars/z-voices.lua index d47e9f745..da8615396 100644 --- a/mods/char-select-extra-chars/z-voices.lua +++ b/mods/char-select-extra-chars/z-voices.lua @@ -3,11 +3,19 @@ if not _G.charSelectExists then return end +local voiceTables = { + [VOICETABLE_TOADETTE] = true, + [VOICETABLE_YOSHI] = true, + [VOICETABLE_PEACH] = true, + [VOICETABLE_DAISY] = true, + [VOICETABLE_BIRDO] = true +} + --- @param m MarioState local function mario_update(m) if is_player_active(m) == 0 then return end local voiceTable = charSelect.character_get_voice(m) - if voiceTable then + if voiceTables[voiceTable] then return charSelect.voice.snore(m) end end @@ -16,7 +24,7 @@ end --- @param sound CharacterSound local function character_sound(m, sound) local voiceTable = charSelect.character_get_voice(m) - if voiceTable then + if voiceTables[voiceTable] then return charSelect.voice.sound(m, sound) end end