Page 1 of 1
Radio
Posted: Sun May 04, 2003 1:33 am
by Molloy
Hi peeps, I need to a radio into my map similar to the one in algiers, playin that old funky music.
Can someone tell me how to do this??
Thx in advance.

Music
Posted: Sun May 04, 2003 9:18 am
by tltrude
Right click on the 2d side of the editor and find sound/speaker. Place the speaker above the radio. Highlight the speaker and hit key N. Type the following key/value.
Key: noise
Value: sound/music/mus_berlin.mp3
Also click on the little box that says "AMBIENT-ON". Hit key N again to close it, and save your map.
I think that will work.
Posted: Sun May 04, 2003 9:24 am
by mohaa_rox
OR:
$radioname loopsound "sound/music/mus_berlin.mp3"
Or use an alias.
script
Posted: Sun May 04, 2003 9:26 am
by tltrude
I don't think the guy even has a script, rox. My way works without one.
Posted: Sun May 04, 2003 9:31 am
by mohaa_rox
Ok.

Cool. 8)
Posted: Sun May 04, 2003 1:54 pm
by jv_map
I don't think any sounds without an alias (or in a .mus file) will work

Posted: Tue May 13, 2003 11:58 pm
by Mainframe
thats dope no script for the music .. nice one

Posted: Wed May 14, 2003 11:02 pm
by Slyk
So, what's the verdict on that one??? Tried all I can think of to get a mp3 to play in a room with a radio and NO go either.........
tutorial
Posted: Thu May 15, 2003 6:44 am
by tltrude
Did you try the tutorial here: /tutorials/ambient_sounds_new.php .
Posted: Thu May 15, 2003 11:10 am
by Slyk
Done that tut before for ambients and such and have my background sound working fine...even can get that second sound to play. HOWEVER, being somewhat of an entity/scripting boob, I want to understand how to make that localized sound play. . . Without, hopefully, tweaking the ubersound file. Or, do I need to add a line to it anyway? I want to play a piece of custom music from my radio. I CAN make the radio play certain 'stock' music/sounds, no issue there...just want the custom sound to play and afraid that I have to put a line in the ubersound and then what? Rename it zzzubersound...etc???
Posted: Fri May 16, 2003 2:32 pm
by panTera
@ Slyk:
For custom localized sounds:
1) Place a "script_model" anywhere in your map where you want to hear the sound from and give it:
key: model
value: fx/dummy.tik
&
key: targetname
value: speaker1 (example)
2) In the script put this:
thread sound
sound:
$speaker1 playsound youralias //or loopsound
3) For custom sounds create a tiki file and save it in 'main/models/sound/yourdir/..'
The tiki should look something like this:
//////////////////////////////////////////////////////////
TIKI
setup
{
path models/fx/dummy
skelmodel dummy3.skd
}
init
{
server
{
classname ScriptModel
rendereffects +dontdraw
notsolid
}
client
{
settiki none
aliascache youralias sound/yourdir/yoursound.wav soundparms 1.5 0.0 1.0 0.0 300 3000 auto loaded maps "t m dm moh obj train yourbspname"
aliascache morealiases? ... put them here
}
}
animations
{
idle dummy3.skc
}
//////////////////////////////////////////////////////////
4) In the _precache script for your map add the lines..:
'cache models/fx/dummy.tik'
'cache models/sound/yourdir/yourtiki.tik'
.. to load your aliases. I've tested this with custom wav's and it works but only if I added the lines to the _precache. I'm not sure though if this can be done with mp3 files.
Posted: Sat May 17, 2003 12:04 am
by Slyk
Thanks for the .scr stuff and idea, I'll give it a go asap and let you know how I screwed it up............I mean, how I did with it!

Failed
Posted: Tue May 27, 2003 5:39 am
by tltrude
My idea of using a speaker to play mp3 music fell through. The speaker will only let you use wav files--click on the sound button in the entity properties window (key N). It would work if you just wanted radio static type sounds.