]> git.lizzy.rs Git - minetest.git/commitdiff
GUIFormSpecMenu: Fix parameter order
authorSmallJoker <mk939@ymail.com>
Sun, 10 Jul 2022 13:34:53 +0000 (15:34 +0200)
committerSmallJoker <mk939@ymail.com>
Sun, 10 Jul 2022 13:34:53 +0000 (15:34 +0200)
Fixes a regression caused by e51f47461 because C++ implicitly converts boolean to float. no matter what.

src/gui/guiFormSpecMenu.cpp

index 342f74b1687d2fb134218ab96a9967d21e91524f..137673b0740acdd5ad693eee701109110d4b4393 100644 (file)
@@ -4498,7 +4498,7 @@ bool GUIFormSpecMenu::OnEvent(const SEvent& event)
                                if ((s.ftype == f_TabHeader) &&
                                                (s.fid == event.GUIEvent.Caller->getID())) {
                                        if (!s.sound.empty() && m_sound_manager)
-                                               m_sound_manager->playSound(SimpleSoundSpec(s.sound, false, 1.0f));
+                                               m_sound_manager->playSound(SimpleSoundSpec(s.sound, 1.0f));
                                        s.send = true;
                                        acceptInput();
                                        s.send = false;
@@ -4543,7 +4543,7 @@ bool GUIFormSpecMenu::OnEvent(const SEvent& event)
 
                                if (s.ftype == f_Button || s.ftype == f_CheckBox) {
                                        if (!s.sound.empty() && m_sound_manager)
-                                               m_sound_manager->playSound(SimpleSoundSpec(s.sound, false, 1.0f));
+                                               m_sound_manager->playSound(SimpleSoundSpec(s.sound, 1.0f));
 
                                        s.send = true;
                                        if (s.is_exit) {
@@ -4568,7 +4568,7 @@ bool GUIFormSpecMenu::OnEvent(const SEvent& event)
                                                }
                                        }
                                        if (!s.sound.empty() && m_sound_manager)
-                                               m_sound_manager->playSound(SimpleSoundSpec(s.sound, false, 1.0f));
+                                               m_sound_manager->playSound(SimpleSoundSpec(s.sound, 1.0f));
                                        s.send = true;
                                        acceptInput(quit_mode_no);
 
@@ -4586,7 +4586,7 @@ bool GUIFormSpecMenu::OnEvent(const SEvent& event)
                                        s.fdefault = L"";
                                } else if (s.ftype == f_Unknown || s.ftype == f_HyperText) {
                                        if (!s.sound.empty() && m_sound_manager)
-                                               m_sound_manager->playSound(SimpleSoundSpec(s.sound, false, 1.0f));
+                                               m_sound_manager->playSound(SimpleSoundSpec(s.sound, 1.0f));
                                        s.send = true;
                                        acceptInput();
                                        s.send = false;