AudioSettingsManager ​
Inherits: RefCounted
AudioSettingsManager handles audio-related functionality in the game. It manages volume controls for different audio buses and emits signals for audio events.
Methods ​
void | apply_settings( settings: SettingsConfig ) |
void | restore_defaults( settings: SettingsConfig ) |
float | get_master_volume( settings: SettingsConfig ) |
void | set_master_volume( settings: SettingsConfig, value: float ) |
float | get_music_volume( settings: SettingsConfig ) |
void | set_music_volume( settings: SettingsConfig, value: float ) |
float | get_sfx_volume( settings: SettingsConfig ) |
void | set_sfx_volume( settings: SettingsConfig, value: float ) |
float | get_ambience_volume( settings: SettingsConfig ) |
void | set_ambience_volume( settings: SettingsConfig, value: float ) |
float | get_voice_volume( settings: SettingsConfig ) |
void | set_voice_volume( settings: SettingsConfig, value: float ) |
float | get_ui_volume( settings: SettingsConfig ) |
void | set_ui_volume( settings: SettingsConfig, value: float ) |
Signals ​
master_volume_changed( newVolume: float ) ​
Signal, emitted when the master volume has changed
music_volume_changed( newVolume: float ) ​
Signal, emitted when the music volume has changed
sfx_volume_changed( newVolume: float ) ​
Signal, emitted when the sound effects volume has changed
ambience_volume_changed( newVolume: float ) ​
Signal, emitted when the ambience volume has changed
voice_volume_changed( newVolume: float ) ​
Signal, emitted when the sound effects volume has changed
ui_volume_changed( newVolume: float ) ​
Signal, emitted when the ambience volume has changed
Constants ​
constMASTER_VOLUME_LABEL ="Master"- Label for master volumeconstMUSIC_VOLUME_LABEL ="Music"- Label for music volumeconstSFX_VOLUME_LABEL ="SFX"- Label for sound effects volumeconstAMBIENCE_VOLUME_LABEL ="Ambience"- Label for ambience volumeconstVOICE_VOLUME_LABEL ="Voice"- Label for voice volumeconstUI_VOLUME_LABEL ="UI"- Label for voice volume
Method descriptions ​
void apply_settings( settings: SettingsConfig ) ​
Applies settings to the audio system
void restore_defaults( settings: SettingsConfig ) ​
Restore default audio settings
float get_master_volume( settings: SettingsConfig ) ​
Gets the master volume
void set_master_volume( settings: SettingsConfig, value: float ) ​
Sets the master volume
float get_music_volume( settings: SettingsConfig ) ​
Gets the music volume
void set_music_volume( settings: SettingsConfig, value: float ) ​
Sets the music volume
float get_sfx_volume( settings: SettingsConfig ) ​
Gets the SFX volume
void set_sfx_volume( settings: SettingsConfig, value: float ) ​
Sets the SFX volume
float get_ambience_volume( settings: SettingsConfig ) ​
Gets the ambience volume
void set_ambience_volume( settings: SettingsConfig, value: float ) ​
Sets the ambience volume
float get_voice_volume( settings: SettingsConfig ) ​
Gets the SFX volume
void set_voice_volume( settings: SettingsConfig, value: float ) ​
Sets the SFX volume
float get_ui_volume( settings: SettingsConfig ) ​
Gets the ambience volume
void set_ui_volume( settings: SettingsConfig, value: float ) ​
Sets the ui volume