audio::AudioManager
Last updated
Last updated
#include <AudioManager.hpp>
bool
bool
bool
bool
float
sf::SoundSource::Status
void
void
void
void
float
This class manages all the sounds and musics of the game Basic operations on background musics and sound effects are supported
load a background music to be played
Parameters:
key the key relative to the AssetLoader
Return: true if the music was loaded
Parameters:
loop if the music should loop, defaulted to true
volume the volume of the music, defaulted to 100
Return: true if the music is playing, false otherwise
play the current background music
Return: true if the music is stopped, false otherwise
stop the current background music
Parameters:
volume0 = min, 100 = max
Return: true if the volume is set, false otherwise
Set the background music volume
Parameters:
loop true to play in loop, false to play once
Set whether or not the stream should loop after reaching the end.
load a sound effect to be played
Parameters:
key the key relative to the AssetLoader
Warning: Do not use, this is for development only
Parameters:
volume0 = min, 100 = max
Return: true if the volume is set, false otherwise
Set the sound effects volume
Updated on 2022-11-13 at 17:21:37 +0100
() =default
(const std::string & key) load a background music to be played
(bool loop =true)
()
(float volume)
()
()
(bool loop)
(const std::string & key) load a sound effect to be played
(const std::string & key)
(float volume)
()