Path3 Masking: Fix for Need For Speed Underground - This got broken when the new GIF Unit went in, probably affects many games which use streams of NOP commands before issuing the mask. Game still requires EE Timing Fix however.

VIF Stall Delay hack: Modified slightly for Onimusha Blade Warriors.  This expects the end of the packet to all be in the VIF1 FIFO (which doesn't exist) and the VIF to have finished, so the Stall is technically ignored now, doesn't hurt SOCOM 2.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@5220 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
refraction 2012-05-22 12:31:56 +00:00
parent cdeaa5e03c
commit de62189834
2 changed files with 12 additions and 2 deletions

View File

@ -295,7 +295,7 @@ __fi void vif1Interrupt()
//NFSHPS stalls when the whole packet has gone across (it stalls in the last 32bit cmd)
//In this case VIF will end
vif1Regs.stat.FQC = min((u16)0x10, vif1ch.qwc);
if(vif1ch.qwc > 0 || !vif1.done)
if((vif1ch.qwc > 0 || !vif1.done) && !CHECK_VIF1STALLHACK)
{
VIF_LOG("VIF1 Stalled");
return;

View File

@ -358,7 +358,17 @@ vifOp(vifCode_MskPath3) {
}
vifOp(vifCode_Nop) {
pass1 { GetVifX.cmd = 0; }
pass1 {
GetVifX.cmd = 0;
if(idx && vif1ch.chcr.STR == true)
{
//Some games use a huge stream of NOPS to wait for a GIF packet to start, alas the way PCSX2 works it never starts
//So the mask can go on before the packet continues, causing desync.
if(((data[1] >> 24) & 0x7f) == 0x6) //Look in to the future and see if we have a mask path 3 command (NFSU)
GetVifX.vifstalled = true; //Stall if we do to get the timing right.
}
}
pass3 { VifCodeLog("Nop"); }
return 0;
}