From beab2b141b173cbb34777993a8563994c964c871 Mon Sep 17 00:00:00 2001 From: Morilli <35152647+Morilli@users.noreply.github.com> Date: Tue, 20 Aug 2024 23:10:38 +0200 Subject: [PATCH] Only force a core name if one exists This could actually not be the case for imported movies for example and is handled elsewhere, but this force parameter breaks rom loading completely when QueuedCoreName is empty. --- src/BizHawk.Client.EmuHawk/MainForm.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/BizHawk.Client.EmuHawk/MainForm.cs b/src/BizHawk.Client.EmuHawk/MainForm.cs index 09b0b4f0ae..d06d0811bf 100644 --- a/src/BizHawk.Client.EmuHawk/MainForm.cs +++ b/src/BizHawk.Client.EmuHawk/MainForm.cs @@ -3644,7 +3644,9 @@ namespace BizHawk.Client.EmuHawk DisplayManager.ActivateOpenGLContext(); // required in case the core wants to create a shared OpenGL context - var result = loader.LoadRom(path, nextComm, ioaRetro?.CorePath, forcedCoreName: MovieSession.QueuedCoreName); + bool result = string.IsNullOrEmpty(MovieSession.QueuedCoreName) + ? loader.LoadRom(path, nextComm, ioaRetro?.CorePath) + : loader.LoadRom(path, nextComm, ioaRetro?.CorePath, forcedCoreName: MovieSession.QueuedCoreName); Game = result ? loader.Game : GameInfo.NullInstance;