No audio implementation of the sound. It is used if audio has been disabled in the game config or the device doesn't support any audio.
It represents a graceful degradation of sound logic that provides minimal functionality and prevents Phaser projects that use audio from breaking on devices that don't support any audio playback technologies.
new NoAudioSound(manager, key, [config])
name | type | arguments | Default | description |
---|---|---|---|---|
manager | Phaser.Sound.NoAudioSoundManager |
Reference to the current sound manager instance. |
||
key | string |
Asset key for the sound. |
||
config | Phaser.Types.Sound.SoundConfig | <optional> | {} |
An optional config object containing default sound settings. |
name | type | description |
---|---|---|
marker | Phaser.Types.Sound.SoundMarker |
Marker object. |
false
Destroys this sound and all associated events and marks it for removal from the sound manager.
false
name | type | arguments | Default | description |
---|---|---|---|---|
markerName | string | Phaser.Types.Sound.SoundConfig | <optional> | '' |
If you want to play a marker then provide the marker name here. Alternatively, this parameter can be a SoundConfig object. |
config | Phaser.Types.Sound.SoundConfig | <optional> |
Optional sound config object to be applied to this marker or entire sound if no marker name is provided. It gets memorized for future plays of current section of the sound. |
false
name | type | description |
---|---|---|
markerName | string |
The name of the marker to remove. |
null
Resumes the sound.
false
Stop playing this sound.
false
name | type | description |
---|---|---|
marker | Phaser.Types.Sound.SoundMarker |
Marker object with updated values. |
false