| Header | Link |
|---|---|
| Purpose | Purpose |
| Use Cases | Use Cases |
| 2D Effect Zone | 2D Effect Zone |
| 3D Audio Mask | 3D Audio Mask |
| Notes | Notes |
Audio geometry nodes shape how spatial sound travels through a scene. AudioMask blocks or muffles sound, AudioEffectZone applies reverb, echo, and dampening inside a volume, and AudioPortal lets sound leak between otherwise blocked spaces. Like physics bodies, each audio node pairs with a child CollisionShape that defines its volume, in both 2D and 3D.
- Muffle sound behind a wall or floor so covered players hear less:
AudioMask2D/AudioMask3Dwith a child shape;audio_maskselects which emittedaudio_layersources it affects. - Add room reverb, echo, or dampening inside a cave, hall, or tunnel:
AudioEffectZone2D/AudioEffectZone3Dwitheffects = [{ reverb_send, echo, dampening }]. - Let sound pass through a doorway or window in an otherwise blocked wall:
AudioPortal2D/AudioPortal3D. - Restrict which emitters a zone or mask touches by layer: emitted
audio_layerversus listener/geometryaudio_mask(see BitMask).
Audio geometry nodes and collision shapes are separate scene nodes.
AudioMask2D, AudioEffectZone2D, AudioPortal2D, AudioMask3D, AudioEffectZone3D, and AudioPortal3D hold audio behavior.
CollisionShape2D and CollisionShape3D hold the volume/portal/mask shape.
In scene files, put collision shapes in separate top-level node blocks.
Set each shape parent to the audio node key.
Audio nodes own world position, range, and spatial filtering. The resource audio API owns one-shot playback and bus control. Use a node when sound must follow scene geometry; use the API when a sound has no persistent world object. Gameplay emits the event, while the audio layer chooses clip, bus, and spatial treatment.
[Zone]
parent = $root
[AudioEffectZone2D]
active = true
audio_mask = []
effects = [{ reverb_send = 0.35 echo = 0.0 dampening = 0.0 }]
[Node2D/]
[/AudioEffectZone2D]
[/Zone]
[ZoneShape]
parent = @Zone
[CollisionShape2D]
shape = { type = quad width = 4.0 height = 4.0 }
[/CollisionShape2D]
[/ZoneShape]
[AudioWall]
parent = $root
[AudioMask3D]
active = true
[/AudioMask3D]
[/AudioWall]
[AudioWallShape]
parent = @AudioWall
[CollisionShape3D]
shape = { type = cube, size = (1, 2, 0.2) }
[/CollisionShape3D]
[/AudioWallShape]
- Audio masks, effect zones, and portals need child collision shapes.
- Audio nodes can have more than one child collision shape.
- Shape local transform comes from the shape node's
Node2DorNode3Ddata. audio_maskignores matching emittedaudio_layer.