Attention: Here be dragons
This is the latest
(unstable) version of this documentation, which may document features
not available in or compatible with released stable versions of Godot.
Checking the stable version of the documentation...
AudioListener2D
繼承: Node2D < CanvasItem < Node < Object
覆寫聽音位置。
說明
當加入場景樹並透過 make_current() 啟用後,此節點將覆寫聽音位置;任一時刻僅能有一個 AudioListener2D 為目前使用。呼叫 make_current() 會停用先前的 AudioListener2D。
若目前 Viewport 中沒有啟用的 AudioListener2D,則以螢幕中心作為聽音點。必須將 AudioListener2D 置於 SceneTree 內才能運作。
方法
void |
|
is_current() const |
|
void |
方法說明
void clear_current() 🔗
停用 AudioListener2D;若其非目前使用則此方法無效。
若此 AudioListener2D 目前啟用,返回 true。
void make_current() 🔗
將此 AudioListener2D 設為啟用並成為聽音點;若已存在其他啟用之 AudioListener2D,則會被停用。
若此節點未加入 SceneTree,本方法無效。