mirror of
https://github.com/neoStudiosLCE/neoLegacy.git
synced 2026-08-20 09:57:09 +00:00
fix: crash when opening UI scenes at sub-720p window size
SWF movie loading crashed with __debugbreak when the window height was below 720px (e.g. after leaving exclusive fullscreen). The fallback chain only tried 720.swf which doesn't exist. Now falls back through 720 -> 1080 so scenes always find a valid SWF.
This commit is contained in:
parent
eb5aa9fa8f
commit
ce2efc1a4d
|
|
@ -310,19 +310,27 @@ void UIScene::loadMovie()
|
||||||
|
|
||||||
if(!app.hasArchiveFile(moviePath))
|
if(!app.hasArchiveFile(moviePath))
|
||||||
{
|
{
|
||||||
app.DebugPrintf("WARNING: Could not find iggy movie %ls, falling back on 720\n", moviePath.c_str());
|
app.DebugPrintf("WARNING: Could not find iggy movie %ls, trying other resolutions\n", moviePath.c_str());
|
||||||
|
|
||||||
|
// Try 720 first, then 1080 as final fallback
|
||||||
moviePath = getMoviePath();
|
moviePath = getMoviePath();
|
||||||
moviePath.append(L"720.swf");
|
moviePath.append(L"720.swf");
|
||||||
m_loadedResolution = eSceneResolution_720;
|
m_loadedResolution = eSceneResolution_720;
|
||||||
|
|
||||||
if(!app.hasArchiveFile(moviePath))
|
if(!app.hasArchiveFile(moviePath))
|
||||||
{
|
{
|
||||||
app.DebugPrintf("ERROR: Could not find any iggy movie for %ls!\n", moviePath.c_str());
|
moviePath = getMoviePath();
|
||||||
|
moviePath.append(L"1080.swf");
|
||||||
|
m_loadedResolution = eSceneResolution_1080;
|
||||||
|
|
||||||
|
if(!app.hasArchiveFile(moviePath))
|
||||||
|
{
|
||||||
|
app.DebugPrintf("ERROR: Could not find any iggy movie for %ls!\n", moviePath.c_str());
|
||||||
#ifndef _CONTENT_PACKAGE
|
#ifndef _CONTENT_PACKAGE
|
||||||
__debugbreak();
|
__debugbreak();
|
||||||
#endif
|
#endif
|
||||||
app.FatalLoadError();
|
app.FatalLoadError();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue