Documentation > Sounds > SoundManager

Parent du composant : Manager
Version: 2.0.3

Constructor SoundManager.New()

This function creates a new SoundManager object.

Return

Return an instance of SoundManager object.

SoundManager:add(File, Type)

This function create and add a sound to the sound table.

File

Path of the file containing the sound.

Type

Type of the sound : 'static', 'stream' or 'queue'

SoundManager:changeVolume(Volume)

This function increase or decrease the volume for all the sound.

Volume

Add this value to the current volume.

SoundManager:pauseSound()

This function pauses all sounds.

SoundManager:setVolume(Volume)

This function sets a new volume value for all sounds.

Volume

New volume to apply to all sounds. Normal volume: 1.

SoundManager:stopAll()

This function stops all musics and sounds.

SoundManager:update(dt)

This function launch the Update function on all sounds.

dt

Delta time.