I'm looking to play music in a certain area, it's easy enough to stop music and play a new theme in a different area... The problem comes when you re-enter the area where the music initially begins. I'm trying to do "If 'test.mp3' isn't playing, then play 'test.mp3'", or something along those lines. What do I put for the expression?
Not sure if it would work but...
I’ll try and drum something up for you and see if I can get it to work on my end.
So it’s basically the same thing you were doing but check for a flag instead of the .mp3.
Oh... and you are using the download version, not the online?
I'd probably guess something like making a game.changedbgmusic
scriptattribute:
if (TypeOf (this, "bgmusic") = "string") {
play sound (this.bgmusic, false, true)
}
else {
stop sound
}
Then when you enter the room, you can just do game.bgmusic = "name of sound file.mp3"
. Changing that attribute automagically plays the sound as long as it's not the same as the last one.