-1

I have mp3 file and I want to play it on my stack.

When I opencard I want to play sound on background.Here code:

on preopencard
   play "/Users/PeshZ/Desktop/sound.mp3"
end preopencard

My sound not played.But on ipad it playing.

What's wrong?

KemChat
  • 151
  • 3
  • 11

2 Answers2

1

To use "play audioclip" the sound file must be uncompressed wav, aif, or au. The LC engine cannot decompress sound files. The audioclip command is very old and has limited use, and it has been deprecated in favor of the player object.

You can play mp3 files on the desktop by setting the filename of a player object to the file path of the sound on disk. Players are much more flexible than the audioclip method.

iOS supports mp3 natively, which is why it plays there.

Jacque
  • 416
  • 2
  • 7
0

try play audioclip "/your/path"

By the way, google can provide this information within 3 seconds: http://lessons.runrev.com/m/4071/l/25230-play-sounds

Tate83
  • 274
  • 1
  • 7
  • 21
  • the lesson in the link says: "It is important to note at this point that audioclips in Livecode can be in either .WAV, .AIFF, or .AU format." did you try one of those formats? – splash21 Jun 04 '14 at 11:07
  • If you can post a link yo your stack/scripts and audio file, we should be able to have a look at it and advise what could be going wrong – Neil Roger Jun 13 '14 at 09:35