mirror of https://github.com/PCSX2/pcsx2.git
VMManager: Fix game fixes not getting applied to BIOS
This commit is contained in:
parent
4d921cc9f9
commit
b6ba3f9059
|
@ -109,6 +109,7 @@ namespace VMManager
|
||||||
static void ClearELFInfo();
|
static void ClearELFInfo();
|
||||||
static void ReportGameChangeToHost();
|
static void ReportGameChangeToHost();
|
||||||
static bool HasBootedELF();
|
static bool HasBootedELF();
|
||||||
|
static bool HasValidOrInitializingVM();
|
||||||
|
|
||||||
static std::string GetCurrentSaveStateFileName(s32 slot);
|
static std::string GetCurrentSaveStateFileName(s32 slot);
|
||||||
static bool DoLoadState(const char* filename);
|
static bool DoLoadState(const char* filename);
|
||||||
|
@ -265,6 +266,12 @@ bool VMManager::HasValidVM()
|
||||||
return (state >= VMState::Running && state <= VMState::Resetting);
|
return (state >= VMState::Running && state <= VMState::Resetting);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool VMManager::HasValidOrInitializingVM()
|
||||||
|
{
|
||||||
|
const VMState state = s_state.load(std::memory_order_acquire);
|
||||||
|
return (state >= VMState::Initializing && state <= VMState::Resetting);
|
||||||
|
}
|
||||||
|
|
||||||
std::string VMManager::GetDiscPath()
|
std::string VMManager::GetDiscPath()
|
||||||
{
|
{
|
||||||
std::unique_lock lock(s_info_mutex);
|
std::unique_lock lock(s_info_mutex);
|
||||||
|
@ -464,7 +471,7 @@ void VMManager::LoadSettings()
|
||||||
if (GSDumpReplayer::IsReplayingDump())
|
if (GSDumpReplayer::IsReplayingDump())
|
||||||
EmuConfig.Speedhacks.vuThread = false;
|
EmuConfig.Speedhacks.vuThread = false;
|
||||||
|
|
||||||
if (HasValidVM())
|
if (HasValidOrInitializingVM())
|
||||||
{
|
{
|
||||||
if (EmuConfig.WarnAboutUnsafeSettings)
|
if (EmuConfig.WarnAboutUnsafeSettings)
|
||||||
WarnAboutUnsafeSettings();
|
WarnAboutUnsafeSettings();
|
||||||
|
@ -476,7 +483,7 @@ void VMManager::LoadSettings()
|
||||||
void VMManager::ApplyGameFixes()
|
void VMManager::ApplyGameFixes()
|
||||||
{
|
{
|
||||||
s_active_game_fixes = 0;
|
s_active_game_fixes = 0;
|
||||||
if (!HasBootedELF())
|
if (!HasBootedELF() && !GSDumpReplayer::IsReplayingDump())
|
||||||
{
|
{
|
||||||
// Instant DMA needs to be on for this BIOS (font rendering is broken without it, possible cache issues).
|
// Instant DMA needs to be on for this BIOS (font rendering is broken without it, possible cache issues).
|
||||||
EmuConfig.Gamefixes.InstantDMAHack = true;
|
EmuConfig.Gamefixes.InstantDMAHack = true;
|
||||||
|
@ -2089,7 +2096,7 @@ void VMManager::ApplySettings()
|
||||||
Console.WriteLn("Applying settings...");
|
Console.WriteLn("Applying settings...");
|
||||||
|
|
||||||
// if we're running, ensure the threads are synced
|
// if we're running, ensure the threads are synced
|
||||||
const bool running = (s_state.load(std::memory_order_acquire) == VMState::Running);
|
const bool running = (GetState() == VMState::Running);
|
||||||
if (running)
|
if (running)
|
||||||
{
|
{
|
||||||
if (THREAD_VU1)
|
if (THREAD_VU1)
|
||||||
|
|
Loading…
Reference in New Issue