Help...anyone can explain this problem to me ? why nothing happen ?
Best Answers
-
tatiang Posts: 11,949
I went ahead and looked at the file and I can tell you the problem. You imported the sound file as a "Sound" in GameSalad but then tried to play it using a Play Music behavior. If you intend to use Play Music, then you have to choose "Music" as the type when you import it. Otherwise, you have to use the Play Sound behavior.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
-
tatiang Posts: 11,949
Your expression is (game.sound +1)/2, when what you want is (game.sound+1)%2. The '%' function (aka modulo) returns the remainder of a division problem. The preferable way to write this in GameSalad is mod(game.sound+1,2) as the '%' symbol won't be supported much longer.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Answers
cc @SmokeyAce73
It's really asking a lot for someone to download your project file, preview it, and then try to guess what is or is not working.
Why not give us some idea of what the problem is?
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
@tatiang
Could you also tell me what is wrong with my project (not sure where my project is, maybe mediafire or wetransfer, just search around I'm sure you'll find it) the problem is that the game is not working, please Skype me with a solution, or if you can't guess my Skype address just send me a fix via gmail (or Hotmail or whatever).
@Socks I was able to deduce that your Google Doc was missing a header and I've fixed it for you.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
@tatiang .. so what should i do...??
>
@tatiang said: "If you intend to use Play Music, then you have to choose "Music" as the type when you import it. Otherwise, you have to use the Play Sound behavior."
It's ok, I've solved it (moments after reading your post), but I also have an entirely unrelated question about platforms moving when the robot jumps on them, send solutions to my Facebook account.
Delete the sound file from the Library in Creator. Then import it back in and when given a choice to import it as a "sound" or "music" file, choose "music." Then use a Play Music behavior to play the sound (select the name of the sound file you imported in the drop-down menu within the behavior).
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
tq very much @tatiang @Socks...i already change like u say and its working and i can push the pause button to stop the sound but..when i push the pause button again to hear the sound back..its not working..what is problem ?
The problem is most probably being caused by the way you have your behaviours / rules (etc) set up.
Without seeing your rules, we can't know how you have it set up. Post a screenshot or your updated project file and we'll tell you why it's not working.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
sure...this my updated project...https://dropbox.com/s/zgw0moqg6y6auvl/playsound.rar
. . . . or even more compatible:
1-game.sound
I always forget that... thanks, @Socks!
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
tq @tatiang...now i know...modules is my problem...huuu..tq so much
yw!
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
when i have another problem...can i ask over here ?
Yes, it's fine to continue a thread with another question you're working on.
But please keep in mind that you've given us very little information so far and it's difficult to help you without having the details about what you're trying to do.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User