sound doesn't work

Post your scripting questions / solutions here

Moderator: Moderators

Post Reply
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

sound doesn't work

Post by wacko »

in my script there are some lines like
$elevator loopsound lighthouse_run, which work perfectly.

Now I added a scriptmodel with targetname/washing and in the scr a line

$washing loopsound elevator_run... just under 'level waittill spawn'

Now this sound doesn't work and console tells me to add an alias to the ubersound.scr. This in my eyes IS an alias in the ubersound.scr. Where am I wrong?
nuggets
General
Posts: 1006
Joined: Fri Feb 28, 2003 2:57 am
Location: U-england-K (england in the UK) :P
Contact:

Post by nuggets »

have you put the elevator.tik in the precache file ? (i think it's called elevator) :P
hope this helps, prob not cos it's all foreign 2 me :-/
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

if you are useing this sound
aliascache elevator_run sound/mechanics/Mec_ElevatorRun_01.wav soundparms 1.5 0.0 1.0 0.0 800 3000 auto loaded maps "m1l3c m4l2 m6l3a m6l3b m6l3c m6l3d m6l3e"
you see the part after the word maps " only maps with those perfixes will play that sound . but you can make a tiki and load the sound in your precache . like so
TIKI

setup
{
path models/fx/dummy
skelmodel dummy3.skd
}

init
{
server
{
classname ScriptModel
rendereffects +dontdraw
notsolid
}
client
{
settiki none

aliascache elevator_run sound/mechanics/Mec_ElevatorRun_01.wav soundparms 1.5 0.0 1.0 0.0 800 3000 auto loaded maps "m1l3c m4l2 m6l3a m6l3b m6l3c m6l3d m6l3e yourmap "
}
}

animations
{
idle dummy3.skc
}
name it yourname.tik and precache it .
that is good when you distribute your map to others . If you only care about your sounds make a ubersounds2.scr and put your map into the obj directory or the dm directory then take every sound from ubersounds that does not have obj or dm in the maplist and put them into your ubersounds2.scr and add " obj dm " to them the game will load your ubersonds2.scr automaticaly so you don't need to do anything else except pak it maybe . One other thing the directory name is part of the map name that is why all sounds in the obj or dm directory will work if you do this and alot of the sounds will work if you put your map in one of those directorys and do nothing because ubersound has most sounds enabled for obj or dm but not all like the sound above
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

Post by wacko »

mmm, something is still missing...

I have a map: dm/shopp.bsp
I have a script: dm/shopp.scr
in this script there is $washing loopsound elevator_run
I have a tiki: models/shopp/shopp.tik
in this tiki is what bdbodger wrote except yourmap is replaced by shopp
I have a precache script: dm/shopp_precache.scr
in this, I wrote cache models/shopp/shopp.tik

and... I still get the message, that it'll need to get an alias in ubersound.scr :cry:
and that lighthouse_run (which is working fine further above in the scr) put into that line like
main:
level waittill spawn
$washing loopsound lighthouse_run
thread elevator_prep
end
doesn't work either...
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

Post by wacko »

But that's how it works!!!
main:
level waittill spawn
exec maps/dm/shopp_precache.scr // that's what was missing!
$washing loopsound elevator_run
thread elevator_prep
Hurray! Hurray! And thanks for your help! Wouldn't have managed my running washing machines without you! :D
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

the directory is part of the map name if your map is shopp and it is in the dm directory then you need to put dm/shopp in the tik or just dm or for that matter just d the list is a prefix list all maps that start with the prefixes will work dosent matter whats after the prefix that is why most sounds work for dm and obj
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

Post by wacko »

yes, i had inserted dm, and as I said, it works now!
Thanks again for helping :D
Post Reply