Added a self modifying code option in the game properties. Turn this on for Monster House and other games that hang or show memory errors. Turn it off for everything else. This fixes Legends of Wrestling.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6005 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
84b5824670
commit
1d2f4283d1
|
@ -45,7 +45,7 @@ SCoreStartupParameter::SCoreStartupParameter()
|
||||||
bSkipIdle(true), bNTSC(false),
|
bSkipIdle(true), bNTSC(false),
|
||||||
bHLE_BS2(true), bUseFastMem(false),
|
bHLE_BS2(true), bUseFastMem(false),
|
||||||
bLockThreads(false),
|
bLockThreads(false),
|
||||||
bEnableCheats(false),
|
bEnableCheats(false), bSMC(false),
|
||||||
bRunCompareServer(false), bRunCompareClient(false),
|
bRunCompareServer(false), bRunCompareClient(false),
|
||||||
bMMU(false), iTLBHack(0), SelectedLanguage(0), bWii(false),
|
bMMU(false), iTLBHack(0), SelectedLanguage(0), bWii(false),
|
||||||
bConfirmStop(false), bHideCursor(false),
|
bConfirmStop(false), bHideCursor(false),
|
||||||
|
@ -70,6 +70,7 @@ void SCoreStartupParameter::LoadDefaults()
|
||||||
bLockThreads = true;
|
bLockThreads = true;
|
||||||
bEnableFPRF = false;
|
bEnableFPRF = false;
|
||||||
bMMU = false;
|
bMMU = false;
|
||||||
|
bSMC = false;
|
||||||
iTLBHack = 0;
|
iTLBHack = 0;
|
||||||
SelectedLanguage = 0;
|
SelectedLanguage = 0;
|
||||||
bWii = false;
|
bWii = false;
|
||||||
|
|
|
@ -78,6 +78,7 @@ struct SCoreStartupParameter
|
||||||
bool bRunCompareClient;
|
bool bRunCompareClient;
|
||||||
|
|
||||||
bool bMMU;
|
bool bMMU;
|
||||||
|
bool bSMC;
|
||||||
int iTLBHack;
|
int iTLBHack;
|
||||||
|
|
||||||
int SelectedLanguage;
|
int SelectedLanguage;
|
||||||
|
|
|
@ -270,7 +270,7 @@ inline void WriteToHardware(u32 em_address, const T data, u32 effective_address,
|
||||||
*(T*)&m_pRAM[em_address & RAM_MASK] = bswap(data);
|
*(T*)&m_pRAM[em_address & RAM_MASK] = bswap(data);
|
||||||
|
|
||||||
// Required for games with self modifying code (e.g. Monster House)
|
// Required for games with self modifying code (e.g. Monster House)
|
||||||
if (Core::g_CoreStartupParameter.bMMU)
|
if (Core::g_CoreStartupParameter.bSMC)
|
||||||
Write_Opcode_JIT(em_address, 0x14141414);
|
Write_Opcode_JIT(em_address, 0x14141414);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -108,6 +108,7 @@ bool BootCore(const std::string& _rFilename)
|
||||||
game_ini.Get("Core", "EnableFPRF", &StartUp.bEnableFPRF, StartUp.bEnableFPRF);
|
game_ini.Get("Core", "EnableFPRF", &StartUp.bEnableFPRF, StartUp.bEnableFPRF);
|
||||||
game_ini.Get("Core", "TLBHack", &StartUp.iTLBHack, StartUp.iTLBHack);
|
game_ini.Get("Core", "TLBHack", &StartUp.iTLBHack, StartUp.iTLBHack);
|
||||||
game_ini.Get("Core", "MMU", &StartUp.bMMU, StartUp.bMMU);
|
game_ini.Get("Core", "MMU", &StartUp.bMMU, StartUp.bMMU);
|
||||||
|
game_ini.Get("Core", "SMC", &StartUp.bSMC, StartUp.bSMC);
|
||||||
// Wii settings
|
// Wii settings
|
||||||
if (StartUp.bWii)
|
if (StartUp.bWii)
|
||||||
{
|
{
|
||||||
|
|
|
@ -292,6 +292,7 @@ void CISOProperties::CreateGUIControls(bool IsWad)
|
||||||
SkipIdle = new wxCheckBox(m_GameConfig, ID_IDLESKIP, _("Enable Idle Skipping"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE|wxCHK_ALLOW_3RD_STATE_FOR_USER, wxDefaultValidator);
|
SkipIdle = new wxCheckBox(m_GameConfig, ID_IDLESKIP, _("Enable Idle Skipping"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE|wxCHK_ALLOW_3RD_STATE_FOR_USER, wxDefaultValidator);
|
||||||
MMU = new wxCheckBox(m_GameConfig, ID_MMU, _("Enable MMU"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE|wxCHK_ALLOW_3RD_STATE_FOR_USER, wxDefaultValidator);
|
MMU = new wxCheckBox(m_GameConfig, ID_MMU, _("Enable MMU"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE|wxCHK_ALLOW_3RD_STATE_FOR_USER, wxDefaultValidator);
|
||||||
TLBHack = new wxCheckBox(m_GameConfig, ID_TLBHACK, _("MMU Speed Hack"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE|wxCHK_ALLOW_3RD_STATE_FOR_USER, wxDefaultValidator);
|
TLBHack = new wxCheckBox(m_GameConfig, ID_TLBHACK, _("MMU Speed Hack"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE|wxCHK_ALLOW_3RD_STATE_FOR_USER, wxDefaultValidator);
|
||||||
|
SMC = new wxCheckBox(m_GameConfig, ID_MMU, _("Enable self modifying code check"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE|wxCHK_ALLOW_3RD_STATE_FOR_USER, wxDefaultValidator);
|
||||||
// Wii Console
|
// Wii Console
|
||||||
sbWiiOverrides = new wxStaticBoxSizer(wxVERTICAL, m_GameConfig, _("Wii Console"));
|
sbWiiOverrides = new wxStaticBoxSizer(wxVERTICAL, m_GameConfig, _("Wii Console"));
|
||||||
EnableProgressiveScan = new wxCheckBox(m_GameConfig, ID_ENABLEPROGRESSIVESCAN, _("Enable Progressive Scan"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE|wxCHK_ALLOW_3RD_STATE_FOR_USER, wxDefaultValidator);
|
EnableProgressiveScan = new wxCheckBox(m_GameConfig, ID_ENABLEPROGRESSIVESCAN, _("Enable Progressive Scan"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE|wxCHK_ALLOW_3RD_STATE_FOR_USER, wxDefaultValidator);
|
||||||
|
@ -349,6 +350,7 @@ void CISOProperties::CreateGUIControls(bool IsWad)
|
||||||
sbCoreOverrides->Add(SkipIdle, 0, wxEXPAND|wxLEFT, 5);
|
sbCoreOverrides->Add(SkipIdle, 0, wxEXPAND|wxLEFT, 5);
|
||||||
sbCoreOverrides->Add(MMU, 0, wxEXPAND|wxLEFT, 5);
|
sbCoreOverrides->Add(MMU, 0, wxEXPAND|wxLEFT, 5);
|
||||||
sbCoreOverrides->Add(TLBHack, 0, wxEXPAND|wxLEFT, 5);
|
sbCoreOverrides->Add(TLBHack, 0, wxEXPAND|wxLEFT, 5);
|
||||||
|
sbCoreOverrides->Add(SMC, 0, wxEXPAND|wxLEFT, 5);
|
||||||
sbWiiOverrides->Add(EnableProgressiveScan, 0, wxEXPAND|wxLEFT, 5);
|
sbWiiOverrides->Add(EnableProgressiveScan, 0, wxEXPAND|wxLEFT, 5);
|
||||||
sbWiiOverrides->Add(EnableWideScreen, 0, wxEXPAND|wxLEFT, 5);
|
sbWiiOverrides->Add(EnableWideScreen, 0, wxEXPAND|wxLEFT, 5);
|
||||||
sbVideoOverrides->Add(ForceFiltering, 0, wxEXPAND|wxLEFT, 5);
|
sbVideoOverrides->Add(ForceFiltering, 0, wxEXPAND|wxLEFT, 5);
|
||||||
|
@ -821,6 +823,11 @@ void CISOProperties::LoadGameConfig()
|
||||||
else
|
else
|
||||||
TLBHack->Set3StateValue(wxCHK_UNDETERMINED);
|
TLBHack->Set3StateValue(wxCHK_UNDETERMINED);
|
||||||
|
|
||||||
|
if (GameIni.Get("Core", "SMC", &bTemp))
|
||||||
|
SMC->Set3StateValue((wxCheckBoxState)bTemp);
|
||||||
|
else
|
||||||
|
SMC->Set3StateValue(wxCHK_UNDETERMINED);
|
||||||
|
|
||||||
if (GameIni.Get("Wii", "ProgressiveScan", &bTemp))
|
if (GameIni.Get("Wii", "ProgressiveScan", &bTemp))
|
||||||
EnableProgressiveScan->Set3StateValue((wxCheckBoxState)bTemp);
|
EnableProgressiveScan->Set3StateValue((wxCheckBoxState)bTemp);
|
||||||
else
|
else
|
||||||
|
@ -907,6 +914,11 @@ bool CISOProperties::SaveGameConfig()
|
||||||
else
|
else
|
||||||
GameIni.Set("Core", "TLBHack", TLBHack->Get3StateValue());
|
GameIni.Set("Core", "TLBHack", TLBHack->Get3StateValue());
|
||||||
|
|
||||||
|
if (SMC->Get3StateValue() == wxCHK_UNDETERMINED)
|
||||||
|
GameIni.DeleteKey("Core", "SMC");
|
||||||
|
else
|
||||||
|
GameIni.Set("Core", "SMC", SMC->Get3StateValue());
|
||||||
|
|
||||||
if (EnableProgressiveScan->Get3StateValue() == wxCHK_UNDETERMINED)
|
if (EnableProgressiveScan->Get3StateValue() == wxCHK_UNDETERMINED)
|
||||||
GameIni.DeleteKey("Wii", "ProgressiveScan");
|
GameIni.DeleteKey("Wii", "ProgressiveScan");
|
||||||
else
|
else
|
||||||
|
|
|
@ -84,7 +84,7 @@ class CISOProperties : public wxDialog
|
||||||
|
|
||||||
wxStaticText *OverrideText;
|
wxStaticText *OverrideText;
|
||||||
// Core
|
// Core
|
||||||
wxCheckBox *CPUThread, *SkipIdle, *MMU, *TLBHack;
|
wxCheckBox *CPUThread, *SkipIdle, *MMU, *SMC, *TLBHack;
|
||||||
// Wii
|
// Wii
|
||||||
wxCheckBox *EnableProgressiveScan, *EnableWideScreen;
|
wxCheckBox *EnableProgressiveScan, *EnableWideScreen;
|
||||||
// Video
|
// Video
|
||||||
|
@ -166,6 +166,7 @@ class CISOProperties : public wxDialog
|
||||||
ID_IDLESKIP,
|
ID_IDLESKIP,
|
||||||
ID_MMU,
|
ID_MMU,
|
||||||
ID_TLBHACK,
|
ID_TLBHACK,
|
||||||
|
ID_SMC,
|
||||||
ID_FORCEFILTERING,
|
ID_FORCEFILTERING,
|
||||||
ID_EFBCOPYDISABLE,
|
ID_EFBCOPYDISABLE,
|
||||||
ID_EFBTOTEXTUREENABLE,
|
ID_EFBTOTEXTUREENABLE,
|
||||||
|
|
Loading…
Reference in New Issue