PDA

View Full Version : Sound Problem!!!


01-15-2009, 07:45 PM
Hey, I am trying to get a song to play off of the internet onto a level on my server, and it isn't working. I even opened a new folder called (mp3).mp3, and it still wont work. How can I play this?

They say that the commands are:

play (filename);

example:

play dogsound.mp3;

It isn't working.

I wish I could just play it off of youtube or something. Is there a way to do this?
If there is, please tell me how.

Thanks

jamerson <3

Pimmeh
01-15-2009, 08:16 PM
Dont double post please, it wont get your answers faster...

01-15-2009, 08:27 PM
Could you tell me the answer?

Matt
01-15-2009, 08:33 PM
Here's an example:

//#CLIENTSIDE
if (playerenters){playlooped http://www.domainhere.com/songs/song1.mp3;
}

That should work, if it doesn't give me the URL of the song you want, and i'll post it in the script and reply here for you.

01-15-2009, 09:17 PM
//#CLIENTSIDE
if (playerenters){playlooped http://www.youtube.com/watch?v=JgA59bBX82E;
}



it wont work D:

Matt
01-15-2009, 09:30 PM
The script is 'trying' to read a 'video' that's why. It will only read audio extensions such as .wav .mp3 ect. From my understanding, YouTube is all videos. Maybe this will give you a better understanding (Straight out of the level editor NPC Script commands):

// file operations:
play - filename; plays a sound/music file or whatever can be played with 'Windows Media Player'
play2 - filename,x,y,volume; plays a sound/music at x,y with the specified volume (1=default volume)
playlooped - filename; plays a sound file (*.wav) looped
stopsound - filename; stops playing a sound file (*.wav)