Well hello.. i need some help... its very small but yea i need 😅

first of all, as you guys know last day I launch my first game and I got a good review .. and the major problem was sound it was too much so i added seething for sound control .. well according to tutorial the sound slid bar is going good but the problem is with toggle button for mute the sound which i snot working well … so did you know that how to fix it ….. its printing hello btw …

if anyone have any more suggestion to improve … are also welcome

You don’t need the if statement there at all.
Since your boolean will be true or false, if it’s false, you will never reach the code where you ACTUALLY set that variable.

Basically, remove the if toggled_on: line and it should work fine.

1 Like

well not working bro… problem is same

Instead of printing hello, do print(toggled_on) and see what the output is when you toggle the check button.

1 Like

Then this should work just fine. Are you sure you’re setting the correct bus index that you want?

1 Like

yes its correct on …

How are you testing if it works or not? Do you have music playing and you expect it to mute when you toggle the button? Since if this code doesn’t work, your volume slider shouldn’t work either.

1 Like

volume slider is working

That doesn’t answer my question, how do you test if the mute toggle works or not? Do you have a sound effect that repeats and constantly plays on the same bus?

1 Like

yes i have sound that plays .. when i start game .. and when i use slider it works but not the button

Then I’m out of options. I’d say try to restart your editor, and maybe delete your .godot folder inside your project files, just to rule out a cache issue, then open godot again and let it re-generate your import files. (PLEASE only delete the FOLDER named .godot, and nothing else. This is a hidden folder, so you might have to enable hidden folders in Windows explorer settings to see it. And please close your editor BEFORE deleting this folder.)

It doesn’t make sense why toggling mute on the same bus wouldn’t work while changing your volume does.

1 Like

ok.. well thanks bro.. i am done today .. its my rest time now.. i will surely reply you after testing this later .. thanks :blush::blush: