mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-23 07:40:14 +00:00
Use absolute tavern music path fallback
This commit is contained in:
parent
071c8ead3b
commit
400e8652d4
1 changed files with 5 additions and 2 deletions
|
|
@ -93,9 +93,12 @@ void AuthScreen::render(auth::AuthHandler& authHandler) {
|
|||
if (music) {
|
||||
music->update(ImGui::GetIO().DeltaTime);
|
||||
if (!music->isPlaying()) {
|
||||
std::string path = "assets/20-taverns.mp3";
|
||||
std::string path = "/home/k/Desktop/wowee/assets/20-taverns.mp3";
|
||||
if (!std::filesystem::exists(path)) {
|
||||
path = (std::filesystem::current_path() / "assets/20-taverns.mp3").string();
|
||||
path = "assets/20-taverns.mp3";
|
||||
if (!std::filesystem::exists(path)) {
|
||||
path = (std::filesystem::current_path() / "assets/20-taverns.mp3").string();
|
||||
}
|
||||
}
|
||||
music->playFilePath(path, true);
|
||||
musicPlaying = music->isPlaying();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue