playing sounds in pak3 (yeah its a noob question)
Moderator: Moderators
playing sounds in pak3 (yeah its a noob question)
i did a small search (i could have done a better one) but i couldnt find the answer ,how do i play a sound i want from the pak3 via script?
the name of the sound is m6l3a_slidingdoors_close.wav and its in pak3.pk3\sound\mechanics
do i type playsound pak3.pk3\sound\mechanics ?
the name of the sound is m6l3a_slidingdoors_close.wav and its in pak3.pk3\sound\mechanics
do i type playsound pak3.pk3\sound\mechanics ?
usually you play sounds by the alias
aliascache door_vault_roll_open sound/mechanics/m6l3a_SlidingDoors_Open.wav soundparms 1.0 0.0 1.0 0.0 160 1600 item loaded maps "m6l3a m6l3b m6l3c m6l3d m6l3e "
but this sound will only play in maps who's name starts with m6l3a or m6l3b or m6l3c or m6l3d or m6l3e
but if you use the script master soundfix you can use it in your map like this
local.master = spawn scriptmaster
local.master aliascache door_vault_roll_open sound/mechanics/m6l3a_SlidingDoors_Open.wav soundparms 1.0 0.0 1.0 0.0 160 1600 item loaded maps "my_mapname_here dm obj "
then you do in your map
$mything playsound door_vault_roll_open
aliascache door_vault_roll_open sound/mechanics/m6l3a_SlidingDoors_Open.wav soundparms 1.0 0.0 1.0 0.0 160 1600 item loaded maps "m6l3a m6l3b m6l3c m6l3d m6l3e "
but this sound will only play in maps who's name starts with m6l3a or m6l3b or m6l3c or m6l3d or m6l3e
but if you use the script master soundfix you can use it in your map like this
local.master = spawn scriptmaster
local.master aliascache door_vault_roll_open sound/mechanics/m6l3a_SlidingDoors_Open.wav soundparms 1.0 0.0 1.0 0.0 160 1600 item loaded maps "my_mapname_here dm obj "
then you do in your map
$mything playsound door_vault_roll_open
darn,more scripting .
well i have 2 understand what im typing here so can u plz tell me and expand my v.small scripting knowledge
so where exactly do i type this?the .scr file?
and what exactly did i type
? does it mean that i want door_ vault_roll_open 2 play this soundm6l3a_SlidingDoors_Open.wav when i type playsound?
and if i change door_ vault_roll_open 2 freaking_cool_sound in the code above as an example would i have 2 type playsound freaking_cool_sound ?
and what about that stuff after soundparms??and my map name ,do i just type map name or map name dm ??
tnx 4 ur reply
well i have 2 understand what im typing here so can u plz tell me and expand my v.small scripting knowledge
Code: Select all
local.master = spawn scriptmaster
local.master aliascache door_vault_roll_open sound/mechanics/m6l3a_SlidingDoors_Open.wav soundparms 1.0 0.0 1.0 0.0 160 1600 item loaded maps "my_mapname_here dm obj "and what exactly did i type
and if i change door_ vault_roll_open 2 freaking_cool_sound in the code above as an example would i have 2 type playsound freaking_cool_sound ?
and what about that stuff after soundparms??and my map name ,do i just type map name or map name dm ??
tnx 4 ur reply
you shouldnt use the plain blue coloring on a black background =p
the base numbers are the BASE settings for the effect. If you change basevolume from 2 to 4 the sound is louder, etc etc.
as for randvolume and pitch, I could only guess based on what it sounds like it is...
this blue is hard to read
but other shades are quite nice =)
the base numbers are the BASE settings for the effect. If you change basevolume from 2 to 4 the sound is louder, etc etc.
as for randvolume and pitch, I could only guess based on what it sounds like it is...
this blue is hard to read
but other shades are quite nice =)
When I am king, you will be first against the wall~


In my experience basevol and randvol don't really work
so you can type whatever fancy numbers you want there
Basepitch does work however, you can use it to transpose your sound up or down (make it sound 'higher' or 'lower'). 1.0 leaves the sound unchanged... randpitch adds a random deviation to basepitch, so that each time the sound is played it sounds a little different
Basepitch does work however, you can use it to transpose your sound up or down (make it sound 'higher' or 'lower'). 1.0 leaves the sound unchanged... randpitch adds a random deviation to basepitch, so that each time the sound is played it sounds a little different
basevol
// UBER SOUND FILE
// Current Format:
// aliascache (?alias?) snd wavfile soundparms basevol volmod basepitch pitchmod minDist maxDist channel loaded|streamed maps "mapstr1 mapstring2 mapstring3 ..."
//
// MIN DIST AND MAX DIST
// sound has linear falloff from minDist to maxDist. Within minDist sound is at normal volume.
------------------------------------------------------------------------
local.master aliascache freaking_cool_sound sound/mechanics/m6l3a_SlidingDoors_Open.wav soundparms 1.0 0.0 1.0 0.0 160 1600 item loaded maps "e t m dm lib moh obj test "
------------------------------------------------------------------------
Base volume has always worked for me, although it does make a differance which channel you use. Using "1.0" for it means the volume within the minimum distance (160 units) will be the same as if you played the wav sound at full volume in Windows Media Player. The sound fades as you leave the minimum distance and move toward the maximum distance (1600 units) where it cuts off completly.
// Current Format:
// aliascache (?alias?) snd wavfile soundparms basevol volmod basepitch pitchmod minDist maxDist channel loaded|streamed maps "mapstr1 mapstring2 mapstring3 ..."
//
// MIN DIST AND MAX DIST
// sound has linear falloff from minDist to maxDist. Within minDist sound is at normal volume.
------------------------------------------------------------------------
local.master aliascache freaking_cool_sound sound/mechanics/m6l3a_SlidingDoors_Open.wav soundparms 1.0 0.0 1.0 0.0 160 1600 item loaded maps "e t m dm lib moh obj test "
------------------------------------------------------------------------
Base volume has always worked for me, although it does make a differance which channel you use. Using "1.0" for it means the volume within the minimum distance (160 units) will be the same as if you played the wav sound at full volume in Windows Media Player. The sound fades as you leave the minimum distance and move toward the maximum distance (1600 units) where it cuts off completly.
THANKS ALOT ALL
wow!!! thanks guys ,i never expected such a wide response
,i now have a better understanding of scripting sound
oh an splaetos i just chose a random colour from the font colour window and clicked it however i can c the colour blue fine,perhaps ur screen is 2 dark
and the background isnt black its dark green btw
so try brightning up ur monitor
edit:just wanna be sure of something here ,in the tut i should write after
loaded maps my map name in quotes right?
then y did tltrude put "e t m dm lib moh obj test "
(what the hell is e t m?).do i type all game modes or my map name or what exactly?
oh an splaetos i just chose a random colour from the font colour window and clicked it however i can c the colour blue fine,perhaps ur screen is 2 dark
edit:just wanna be sure of something here ,in the tut i should write after
loaded maps my map name in quotes right?
then y did tltrude put "e t m dm lib moh obj test "
(what the hell is e t m?).do i type all game modes or my map name or what exactly?
e t m
All that "e t m lib" stuff is for Spearhead and Breakthrough, so is not really needed. I was just thinking of what would work for every game type and game, but the local.master work around does not work for Spearhead and Breakthrough anyway.
-
agentmad007
- Brigadier General
- Posts: 570
- Joined: Tue Feb 24, 2004 3:52 pm
damn after a long reading about the sound i got my answer
the local master script dont work for moh breakthrough !!!!!!!!
grrrrrrrrrr
i got a trigger use with a setthread how do i go to put several sounds one after one ...........without local master
Ty
Btw: if igot to make a tik file plz explain coze i dont understand those stuffffff
the local master script dont work for moh breakthrough !!!!!!!!
grrrrrrrrrr
i got a trigger use with a setthread how do i go to put several sounds one after one ...........without local master
Ty
Btw: if igot to make a tik file plz explain coze i dont understand those stuffffff



