How to create a Mute button ...
dkurien
Member Posts: 7
How do I create a mute button that will mute all sound ...
I am using Game Salad Creator for Windows. On pressing the Mute button, I'm trying to "Change Attribute":
set: game.Audio.Sound Volume
to: 0
but nothing seems to happen. It's driving me nuts, and I was wondering if anyone could help me.
Much appreciate it.
Denny (noob)
I am using Game Salad Creator for Windows. On pressing the Mute button, I'm trying to "Change Attribute":
set: game.Audio.Sound Volume
to: 0
but nothing seems to happen. It's driving me nuts, and I was wondering if anyone could help me.
Much appreciate it.
Denny (noob)
Best Answer
-
tenrdrmer Posts: 9,934Merged Threads. By report it I meant click the contact support link and actually report it to it so they will for sure know its there and can assign someone to investigate.
Answers
To mute, say that when someone touches the mute button:
Change attribute: game.gameMusic to 0.
This way all sound will shut off.
Right now I have sound playing right at the beginning of the scene using the "Play Sound" action:
play sound: thunder.ogg
at volume: 1
at pitch: 1
run to completion
Where and how should I set the expression 'volume = gameMusic' ?
Appreciate your help.
Thanks,
Denny
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
I got my sound playing at the beginning of the scene using the "Play Sound" action:
play sound: thunder.ogg
at volume: 1
at pitch: 1
run to completion
Then I have a button, which once "touched" I ask it to change attribute:
set: Game.Audio.Sound.Volume
to: 0
... nothing happens
:-S
Create an attribute called playSound.
This can be controlled by a button on your setting screen or whatever that toggles the playSound attribute to true/false.
Then whenver you want to play a sound make a behavior that says:
When your event occurs
If playSound is true
playsound thunder.ogg
Jamie
http://jamie-cross.net/posts/ ✮ Udemy: Introduction to Mobile Games Development ✮ Learn Mobile Game Development in One Day Using Gamesalad ✮ My Patreon Page
also a chance the template wont even work on your windows gamesalad.
the windows version works fine as far as I have seen. if you think you have found a bug send a report in. OTherwise unless you just want a mac like the rest of us you dont need to go buy a mac just to use gamesalad.
except i didnt care about buying game salad 3 years ago? i heard about it recently after getting my first ipad, tried it, found a lot of the tutorials didnt translate well and the templates often had problems in windows, and i couldnt do iphone games with it so i bought a mac. i dont know why this is offending you so much. the windows version didnt have the expresion editor, which is a feature i thought was nice. and a lot of the templates didnt work with it.
i have a job and make money so i bought a mac, and poof i had the stuff i wanted.
I'm in no way hating on pcs, my day job is as a game artist and in general the majority of game dev is all pc based
i apologize if somehow i've offended you by prefering gamesalad on mac. it is the only thing i use the mac for.