Hello, i would like to know how to add looping music with mapadd.
I thought yesterday that music would add some good ambience into my map.
Thanks in advance.
(Pardon me for my not-so-good thread making )
How to add looping music with mapadd?
Re: How to add looping music with mapadd?
Code: Select all
Add
{
// This plays the sound. DO NOT TRIGGER THIS ENTITY.
"ambient_generic"
{
"health" "10"
"message" "path/to/sound.file"
"pitch" "100"
"pitchstart" "100"
"radius" "1250"
"spawnflags" "49"
"targetname" "snd_1"
"origin" "-872 -1376 530"
}
// This is the trigger for the sequence. ONLY TRIGGER THIS ENTITY TO START, DO NOT TRIGGER THE OTHERS INDIVIDUALLY!
"logic_relay"
{
"spawnflags" "0"
"targetname" "rly_snd1"
"origin" "-848 -1376 530"
"OnTrigger" "snd_1,PlaySound,,0,-1"
"OnTrigger" "tim_snd1_looper,Enable,,0,-1"
"OnTrigger" "rly_snd1_fadetrigger,Enable,,0,-1"
}
// This is the timer to loop the sound. DO NOT TRIGGER THIS ENTITY.
"logic_timer"
{
// Change this vvv to match the time the sound ends (time is in seconds)
"RefireTime" "240"
"spawnflags" "0"
"StartDisabled" "1"
"targetname" "tim_snd1_looper"
"origin" "-824 -1376 530"
"OnTimer" "snd_1,PlaySound,,0,-1"
}
// This is the trigger to stop the sound (with a 1.5 second fade). ONLY TRIGGER THIS ENTITY TO STOP, DO NOT TRIGGER THE OTHERS INDIVIDUALLY!
"logic_relay"
{
"spawnflags" "0"
"StartDisabled" "1"
"targetname" "rly_snd1_fadetrigger"
"origin" "-800 -1376 530"
"OnTrigger" "snd_1,FadeOut,1.5,0,-1"
"OnTrigger" "tim_snd1_looper,Disable,,0,-1"
"OnTrigger" "!self,Disable,,0,-1"
}
}
Apparently, Valve can't make games beyond the number 2.
I think the only time we'll get a Source SDK code update is when it starts having purchasable hats integrated, i.e. hatconomy.
Please do not make assumptions you are not knowledgeable enough to make - that just backfires on yourself.
Tick me off, and I'll be sure to give you the golden treatment. Haven't you heard? Silence is golden.
I think the only time we'll get a Source SDK code update is when it starts having purchasable hats integrated, i.e. hatconomy.
Please do not make assumptions you are not knowledgeable enough to make - that just backfires on yourself.
Tick me off, and I'll be sure to give you the golden treatment. Haven't you heard? Silence is golden.
Re: How to add looping music with mapadd?
Alright, thanks for help
Re: How to add looping music with mapadd?
You'll have to change the origin's to a location in the map you're mapadding for otherwise you could throw ents out of the map.
'I would probably smarten up before you meet Violet'.
'She has zero tolerance for idiots'.
fug's Obsidian files
fug's Obsidian clips
Obsidian wiki
Obsidian Map Database
'She has zero tolerance for idiots'.
fug's Obsidian files
fug's Obsidian clips
Obsidian wiki
Obsidian Map Database
Re: How to add looping music with mapadd?
Well, afaik placing logical entities outside the map after the map (e.g. with a MapAdd) is compiled is perfectly fine, because it's impossible for a map to leak post-compile. Just don't place props or other visible entities outside the map.
Apparently, Valve can't make games beyond the number 2.
I think the only time we'll get a Source SDK code update is when it starts having purchasable hats integrated, i.e. hatconomy.
Please do not make assumptions you are not knowledgeable enough to make - that just backfires on yourself.
Tick me off, and I'll be sure to give you the golden treatment. Haven't you heard? Silence is golden.
I think the only time we'll get a Source SDK code update is when it starts having purchasable hats integrated, i.e. hatconomy.
Please do not make assumptions you are not knowledgeable enough to make - that just backfires on yourself.
Tick me off, and I'll be sure to give you the golden treatment. Haven't you heard? Silence is golden.
Re: How to add looping music with mapadd?
Sorry didn't get back here, you could be right. I'm not sure.
'I would probably smarten up before you meet Violet'.
'She has zero tolerance for idiots'.
fug's Obsidian files
fug's Obsidian clips
Obsidian wiki
Obsidian Map Database
'She has zero tolerance for idiots'.
fug's Obsidian files
fug's Obsidian clips
Obsidian wiki
Obsidian Map Database