Env soundscape triggerable

From Valve Developer Community

This point-based entity is available in all Source games. In code it is represented by class CEnvSoundscapeTriggerable (http://localhost/class_c_env_soundscape_triggerable.html), defined in soundscape.cpp (http://localhost/soundscape_8cpp-source.html).

Table of contents

Entity Description

A point entity that works like the env_soundscape entity except that it works in conjunction with the trigger_soundscape entity to determine when a player hears it.
Image:note.png Note: This entity has the same keyvalues, (non-existant) flags, inputs, and outputs as env_soundscape.




Keyvalues

Defines the name that other entities refer to this entity by.
  • hammerid [Episode Two Update]
<integer readonly> This id is used for debugging purposes in Hammer.
Specifies the targetname of this entity's Parent in a movement hierarchy. Child entities move with their Parent.
  • StartDisabled
<boolean>
  • radius
<integer> Radius - If set to -1, then the player can hear the soundscape as long as he can see it (regardless of distance to it).
  • soundscape
<string> Soundscape - The name of the soundscape to use. Corresponds to an entry in the soundscapes_*.txt file in the hl2/scripts directory (normally packed into the source engine.gcf file).
Literal Value Description
Nothing Nothing
Automatic Automatic
Automatic_Dialog Automatic (dialog)
GenericIndoor Indoor
GenericOutdoor Outdoor
  • position0-7
<target_destination> Sound Position 0-7 - Sound positions that will be referenced inside the soundscape text file. Usually used to position a set of sounds within the world.

Inputs

  • Kill
Removes this entity from the world.
Removes this entity and all its children from the world.
  • AddOutput <string>
Evaluates a keyvalue/output on this entity. It can be potentially very dangerous, use with care.
Format: <key> <value>
Format: <output name> <targetname>:<inputname>:<parameter>:<delay>:<max times to fire (-1 == infinite)>
Causes this entity's OnUser1-4 outputs to be fired. See User Inputs and Outputs.
Changes the entity's parent in the movement hierarchy.
Change this entity to attach to a specific attachment point on its parent. Entities must be parented before being sent this input. The parameter passed in should be the name of the attachment.
Change this entity to attach to a specific attachment point on it's parent. Entities must be parented before being sent this input. The parameter passed in should be the name of the attachment. The entity will maintain it's position relative to the Parent's Origin and Angles at the time it is attached.
Removes this entity from its current movement hierarchy.
  • Enable
Enable this entity.
  • Disable
Disable this entity.
  • Disabled
Image:Todo.png To do: Write description. (It's not a typo - both Disable and Disabled exists.)
  • ToggleEnabled
Toggle the soundscape enabled state.

Outputs

Fired in response to FireUser1-4 inputs. See User Inputs and Outputs.
!activator = activator
  • OnPlay
Fired when this soundscape becomes the active one.