Adding Existing Sounds to Stuff (Bare with me lol)

If you're looking for mapping help or you reckon you're a mapping guru, post your questions / solutions here

Moderator: Moderators

Post Reply
Shifty
Map Reviewer
Posts: 717
Joined: Sun Dec 15, 2002 11:53 pm
Location: UK
Contact:

Adding Existing Sounds to Stuff (Bare with me lol)

Post by Shifty »

Hi

I've built a metal sliding door which is situated on the floor and leads down to the sewers/underground currently it just plays the normal door sound (not good) but i've found something i'd like to use its in pak3.pk3 -> mechanics -> Fence_Open.wav

I've done some looking around here so would it be something like this in the script

Code: Select all

$the_door loopsound Fence_Open
If so how do i connect the script to this item? do i have to make it say a script object if so how i'm a bit rusty on this????

Cheers

Shifty
.MDT Webmaster, Mapper, Moddeler & Concept Artist
.Map Reviewer
Image
http://www.shiftys-bunker.tk Under Construction
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

Use a script_model with model fx/dummy.tik. Give it a targetname like 'doorsound'.

Then type:
$doorsound playsound mycoolcustomdoorsoundaliasname

To define the mycoolcustomdoorsoundaliasname alias, use the 'new' ubersound work-around method as described in the sticky over at the scripting forum, or read the custom sounds tutorial.

Note that this applies to mohaa only, not to sh or breakthrough.
Image
M&M
General
Posts: 1427
Joined: Sun Sep 14, 2003 1:03 am
Location: egypt
Contact:

Post by M&M »

im just curious but doesnt the door have a key in the entity window that changes the sound ?i think it was called door_open or something like that,there is also another one for closing
Image
User avatar
Axion
Major General
Posts: 683
Joined: Mon Sep 29, 2003 5:14 am
Location: Northern California
Contact:

Post by Axion »

If you want the dooor to just play a generic metal sound, enter this in the entity window-

doortype metal
"The work of a thousand years is nothing but rubble."
- Dr. Carl Goerdeler (1943)
Visit my mapping site: http://www.freewebs.com/axion9
Image
M&M
General
Posts: 1427
Joined: Sun Sep 14, 2003 1:03 am
Location: egypt
Contact:

Post by M&M »

yeah ,thats what i ment :wink:
Image
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

speaker

Post by tltrude »

I wouldn't add a speaker, as jv_map said, because the normal sounds will still be heard as well--using a func_door.

Here are the key/values to change the sounds of the door.

Key: sound_close_end
Value: snd_step_paper // null.wav to kill normal sound

Key: sound_close_start
Value: fence_roll_open

Key: sound_open_end
Value: snd_step_paper // null.wav to kill normal sound

Key: sound_open_start
Value: fence_roll_open


Now that you have "fence_roll_open" in the door entity, you need to make that alias work for your map's game type--normally only works for map m2l2 (singleplayer), as you can see in this line from the ubersound script.

aliascache fence_roll_open sound/mechanics/Fence_Open.wav soundparms 1.2 0.0 1.1 0.0 160 1600 item loaded maps "m2l2 "

To fix it, you'll need to add this above "level waittill prespawn" in your map's script.

Code: Select all

local.master = spawn ScriptMaster
local.master aliascache fence_roll_open sound/mechanics/Fence_Open.wav soundparms 1.2 0.0 1.1 0.0 160 1600 item loaded maps "m dm obj train "
Hope that helps!
Tom Trude,

Image
Post Reply