Class SoundEventDefinition
Namespace: ValveResourceFormat.Renderer.Audio
Assembly: Renderer.dll
A sound event definition with its properties parsed out of the key-values once. Also carries mutable per-event playback state (last picked track, last play time).
public sealed class SoundEventDefinitionInheritance
object ← SoundEventDefinition
Properties
BlockDuration
Gets how long replays are blocked for, in seconds.
public float BlockDuration { get; }Property Value
float
BlockMatchingEvents
Gets whether replays within SoundEventDefinition.BlockDuration are dropped ("block_matching_events", or "block_match_this_event" in hlvr).
public bool BlockMatchingEvents { get; }Property Value
bool
Data
Gets the underlying key-values, with the "base" chain already merged in.
public KVObject Data { get; }Property Value
KVObject
Delay
Gets the delay in seconds before the sound starts.
public float Delay { get; }Property Value
float
EnableRetrigger
Gets whether the event replays itself on an interval.
public bool EnableRetrigger { get; }Property Value
bool
FadeIn
Gets the fade-in length in seconds, zero to start at full volume.
public float FadeIn { get; }Property Value
float
FadeOut
Gets the stop-fade length in seconds, zero to use the caller's fallback.
public float FadeOut { get; }Property Value
float
Name
Gets the sound event name this definition was loaded under.
public string Name { get; }Property Value
string
OcclusionIntensity
Gets how strongly geometry between the listener and the sound attenuates it ("occlusion_intensity", or "occlusion_scale" in hlvr): 0 (the default) is not occludable, 1 is fully muted when blocked.
public float OcclusionIntensity { get; }Property Value
float
Pitch
Gets the base playback rate multiplier.
public float Pitch { get; }Property Value
float
Position
Gets the position, or null when all zero (an authoring placeholder).
public Vector3? Position { get; }Property Value
PositionOffset
Gets the offset added to the position (e.g. footsteps play 20 units above the ground).
public Vector3 PositionOffset { get; }Property Value
RetriggerIntervalMax
Gets the upper bound of the retrigger interval, in seconds.
public float RetriggerIntervalMax { get; }Property Value
float
RetriggerIntervalMin
Gets the lower bound of the retrigger interval, in seconds.
public float RetriggerIntervalMin { get; }Property Value
float
SetChildPosition
Gets whether child events play at this event's position ("set_child_position", e.g. a footstep's gear rustle follows the player), on by default for "csgo_mega". When false, children use their own authored positions. Read by the base SoundEvent.StartAsChild(SoundEvent), so it lives here regardless of event type.
public bool SetChildPosition { get; }Property Value
bool
Type
Gets the sound event type ("csgo_mega"), empty when the definition has none.
public string Type { get; }Property Value
string
Volume
Gets the base volume, replaced by SoundEvent.VolumeOverride when set. Unit depends on the sub type: CS2 events author this linear (0-1); Deadlock events author it in decibels.
public float Volume { get; }Property Value
float
Methods
ToString()
Returns a string that represents the current object.
public override string ToString()Returns
string
A string that represents the current object.

