Get the build fail to actually play and keep the building sound looping until the build is done.
This commit is contained in:
parent
2035a6dd00
commit
95cd84b09d
8 changed files with 8 additions and 9 deletions
|
@ -17,7 +17,7 @@ using namespace nlohmann;
|
|||
using namespace ImGui;
|
||||
using std::string;
|
||||
|
||||
void SoundQuip::load(json &data, const char *file_key) {
|
||||
void SoundQuip::load(json &data, const char *file_key, bool loop) {
|
||||
auto audio = data["audio"];
|
||||
json::string_t file_name = audio[file_key].template get<string>();
|
||||
|
||||
|
@ -26,6 +26,7 @@ void SoundQuip::load(json &data, const char *file_key) {
|
|||
}
|
||||
|
||||
sound.setBuffer(buffer);
|
||||
sound.setLoop(loop);
|
||||
}
|
||||
|
||||
void SoundQuip::play() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue