Adding sounds. Help please.

LightBeamLightBeam berkata

lama dahulu | Post #1
I am having trouble adding sounds in my game when I use AS3.
The way I saw it being done is importing the sound file to the library then right click on it > properties. Check the box where it says Export to actionscript, and give it a class name. Then in the actioscript file I wrote the following code.

sound = new Sound(new URLRequest("nameofthefile.mp3");
sound.play();

This works locally, but when I upload it to nonoba it doesn't play anything. Any ideas? Appreciate your help.

LightBeamLightBeam berkata

lama dahulu | Post #2
Ok I figured it our. URLRequest doesn't work.

PatheticAssassinPatheticAssassin berkata

8 bulan yang lalu | Post #3
Glad you figured it out, sorry you had no help from me in the forums

Balas ke thread

Daftar sekarang untuk membalas thread

Mainsini

mainsini.com adalah situs game indie dimana anda bisa bermain game secara single ataupun multiplayer dengan gratis.

Tools untuk Developer

Jika anda adalah game developer flash, kami punya tools istimewa yang bisa membantu anda membuat game yang lebih keren.

Game Keren

Mainkan game flash online terbaik kami, Sepenuhnya gratis. Tunggu apa lagi?

Copyright ©2007-2012 Mainsini™ - All rights reserved.34.002ms on SERVER34097