From 44b03a06a0ad910098d25eebb6e521aaa24240e7 Mon Sep 17 00:00:00 2001 From: Kelsi Date: Thu, 5 Feb 2026 16:26:45 -0800 Subject: [PATCH] Avoid hardcoded login video path --- src/ui/auth_screen.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ui/auth_screen.cpp b/src/ui/auth_screen.cpp index 97d7c546..b1bd1ca4 100644 --- a/src/ui/auth_screen.cpp +++ b/src/ui/auth_screen.cpp @@ -45,7 +45,11 @@ void AuthScreen::render(auth::AuthHandler& authHandler) { if (!videoInitAttempted) { videoInitAttempted = true; - backgroundVideo.open("assets/startscreen.mp4"); + std::string videoPath = "assets/startscreen.mp4"; + if (!std::filesystem::exists(videoPath)) { + videoPath = (std::filesystem::current_path() / "assets/startscreen.mp4").string(); + } + backgroundVideo.open(videoPath); } backgroundVideo.update(ImGui::GetIO().DeltaTime); if (backgroundVideo.isReady()) {