Page 1 of 1
Easiest way to trigger a sound that can be heard by all?
Posted: Wed Oct 15, 2003 1:53 am
by sysQuik
What would be the easiest way to trigger a sound from script that is heard by everyone in the map, regardless of where they are located? I looked in tow_dm.scr as I think the final countdown of the bomb is heard by everyone, but I didn't understand what made it heard by everyone. Do I need to get into tikis or ubersound? I found a lot of great info here in the forum, but I'm not sure which approach to use or how to make it heard by all.
Thanks for your help!
Sysquik
Sound
Posted: Wed Oct 15, 2003 1:58 am
by tltrude
Is it a custom sound, or one that is in the game already? Also, is it a wav or mp3?
Posted: Wed Oct 15, 2003 2:44 am
by sysQuik
In game sound, wav file. Not exactly sure which one yet. Thanks for the speedy reply! I really appreciate it.
Sysquik
Posted: Wed Oct 15, 2003 7:11 am
by jv_map
Make it play on the local channel (you can define a channel in the alias definition) or add "levelwide" after the playsound command.
Example:
level.alarm_sound loopsound alarmbell local.vol "levelwide"
(don't know if it works with playsound as well)
Solution! Script contained
Posted: Thu Oct 16, 2003 6:33 am
by sysQuik
Thanks for your response jv_map. Here's the script:
Code: Select all
main:
exec global/ambient.scr
level waittill prespawn
local.master = spawn ScriptMaster
local.master aliascache snd_river sound/amb/Amb_RainWindow_01.wav soundparms 1.0 0.2 1.0 0.2 10000 2000 auto loaded maps "obj dm"
level waittill spawn
thread sound
end
sound:
while (1)
{
$sound_trigger waittill trigger
$river_sound loopsound snd_river
iprintln "Sound Triggered"
}
end
Thanks to your excellent tut, I have the problem solved. I just set the min value to 10000 which should be larger than my map. What if I did just want to edit the ubersound.scr, how would I make MOHAA use the ubersound.scr in my pak file instead of the standard one in MOHAA?
Thanks again for all your help!
SySquik

Re: Solution! Script contained
Posted: Thu Oct 16, 2003 3:20 pm
by jv_map
sysQuik wrote:What if I did just want to edit the ubersound.scr, how would I make MOHAA use the ubersound.scr in my pak file instead of the standard one in MOHAA?
Simply make sure the filename of your pak has a later order in the alphabet than the stock paks. For instance prefix a 'z' (or more

).
Like: zzzysquick.pk3

(though sysquick.pk3 would work too)
Posted: Sat Oct 18, 2003 7:11 am
by sysQuik
Excellent! Thanks for the info. Sounds like a pak turf war for zzzzzzzz9999.pk3.
Sysquik