W3cubDocs

/Godot 4.2

AudioListener3D

Inherits: Node3D < Node < Object

Overrides the location sounds are heard from.

Description

Once added to the scene tree and enabled using make_current, this node will override the location sounds are heard from. This can be used to listen from a location different from the Camera3D.

Methods

void

clear_current ( )

Transform3D

get_listener_transform ( ) const

bool

is_current ( ) const

void

make_current ( )

Method Descriptions

void clear_current ( )

Disables the listener to use the current camera's listener instead.

Transform3D get_listener_transform ( ) const

Returns the listener's global orthonormalized Transform3D.

bool is_current ( ) const

Returns true if the listener was made current using make_current, false otherwise.

Note: There may be more than one AudioListener3D marked as "current" in the scene tree, but only the one that was made current last will be used.

void make_current ( )

Enables the listener. This will override the current camera's listener.

© 2014–present Juan Linietsky, Ariel Manzur and the Godot community
Licensed under the Creative Commons Attribution Unported License v3.0.
https://docs.godotengine.org/en/4.2/classes/class_audiolistener3d.html