Skip to content

Commit

Permalink
Dead or Alive 2 fix
Browse files Browse the repository at this point in the history
  • Loading branch information
bigianb committed Dec 22, 2023
1 parent a9f54cb commit f766c45
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Source/iop/Iop_Intrman.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,12 @@ uint32 CIntrman::DisableIntrLine(CMIPS& context, uint32 line, uint32 res)
mask.f &= ~(1LL << line);
context.m_pMemoryMap->SetWord(CIntc::MASK0, mask.h0);
context.m_pMemoryMap->SetWord(CIntc::MASK1, mask.h1);
if(res != 0)
{
uint32& statusRegister = context.m_State.nCOP0[CCOP_SCU::STATUS];
uint32* state = reinterpret_cast<uint32*>(m_ram + res);
(*state) = statusRegister & CMIPS::STATUS_IE;
}
return 0;
}

Expand Down Expand Up @@ -210,7 +216,7 @@ uint32 CIntrman::SuspendInterrupts(CMIPS& context, uint32 statePtr)
uint32 CIntrman::ResumeInterrupts(CMIPS& context, uint32 state)
{
#ifdef _DEBUG
CLog::GetInstance().Print(LOGNAME, FUNCTION_RESUMEINTERRUPTS "();\r\n");
CLog::GetInstance().Print(LOGNAME, FUNCTION_RESUMEINTERRUPTS "(0x%x);\r\n", state);
#endif
uint32& statusRegister = context.m_State.nCOP0[CCOP_SCU::STATUS];
if(state)
Expand Down
3 changes: 3 additions & 0 deletions patches.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,7 @@
<Executable Name="SLES_501.76;1" Title="Oni" Region="EU">
<Patch Address="0x001cef7c" Value="0x00000000 // bc0f $001cef7c" Description="Fix hang by skip branch if copro 0 condition false." />
</Executable>
<Executable Name="SCES_500.03;1" Title="Dead or Alive 2" Region="EU">
<Patch Address="0x002b4c44" Value="0x24060000" Description="Make the file reading RPC call synchronous. Boot hangs without this." />
</Executable>
</Patches>

0 comments on commit f766c45

Please sign in to comment.