12-Jul-2023
Allows you to set up specific ambient effects for increasing the sound experience and making it consistent with the visuals of your map.
Keyvalues |
OnDestroy Function ondestroyfn : Name of the function to use from already parsed .as script files when entity is destroyed (killed) in any way. If the function belongs to namespace, you must use prefix with the namespace name (e.g. mynamespace::MyFunction) for the keyvalue.
Name targetname : Set name of env_sound so other entities can trigger it to apply sound effect to entities in radius- only when 'Use only' and 'Radius' are used. Every trigger use-type works uniformly. Can be kill-targeted but already applied effects persist.
Radius radius : Radius, in units, in which a player has to be for the ambient effect to change for him. The ambient effect will stay after leaving the radius, until another env_sound is entered. If set to 0, the radius won't be used, this is useful when entity is "Use only".
Room Type roomtype : Pick the ambient effect here. There are 29 options.
1 : USE Only : If selected, the env_sound apply sound effect directly (if radius is 0), or will check for players inside that radius single time whenever it is triggered.
When a player spawns within the radius of an env_sound, he won't be affected.
Being in an env_sound for too short of a time won't cause its effects to be applied on the player.
An env_sound effect is not reset to normal after a map change. If you do not want to use env_sounds in your map, you should at least add a few around its start locations to properly reset the effect.