I am trying to add background music which can be stopped and played by the player in the game i am creating. I googled how to do it and added the following example code to a button:
on mouseUp
play audioClip "/Users/davidwilliams/desktop/audiolesson/hello.wav"
end mouseUp
When i substituted in my stuff, all i got was thing crackling sound. Could someone please explain why, and what i can do.
thanks
edit: the file is not compressed.
adding sound not working
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
adding sound not working
Last edited by star0629 on Sat Jan 11, 2014 4:10 pm, edited 1 time in total.
Re: adding sound not working
Hi David,
LC is EXTREMELY picky, when it comes to PLAY audo and video files!
Is the WAV sound compressed somehow? LC does not like that.
Please post some info about the sound format if possible.
Best
Klaus
LC is EXTREMELY picky, when it comes to PLAY audo and video files!
Is the WAV sound compressed somehow? LC does not like that.

Please post some info about the sound format if possible.
Best
Klaus
Re: adding sound not working
Hi...
You have the file you want to play on the desktop, so use
use
if you have imported the .wav file into your stack...
You have the file you want to play on the desktop, so use
Code: Select all
play "/Users/davidwilliams/desktop/audiolesson/hello.wav"
Code: Select all
play audioclip "hello.wav"
Re: adding sound not working
AH! Good catch! 
