mirror of https://github.com/PCSX2/pcsx2.git
Now Area 51 works :P Ok this probably fixes Tekken 4 properly, id missed some bits when moving some of the code over, which would have caused it not to work right, plus my favourite = instead of == slipped in..
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3423 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
19c03083a2
commit
8e38cbb5eb
|
@ -440,11 +440,20 @@ __forceinline int GIFPath::ParseTagQuick(GIF_PATH pathidx, const u8* pMem, u32 s
|
|||
size *= 2;
|
||||
u32 len = aMin(size, (nloop * numregs)-curreg);
|
||||
|
||||
if(len < (nloop * numregs)-curreg)
|
||||
if(len < ((nloop * numregs)-curreg))
|
||||
{
|
||||
const int nloops_copied = len / numregs;
|
||||
const int regs_not_copied = len % numregs;
|
||||
|
||||
DevCon.Warning("Quick Hit it path %d Please report if you experience problems", pathidx + 1);
|
||||
curreg += regs_not_copied;
|
||||
nloop -= len / numregs;
|
||||
nloop -= nloops_copied;
|
||||
|
||||
if(curreg >= numregs)
|
||||
{
|
||||
--nloop;
|
||||
curreg -= numregs;
|
||||
}
|
||||
}
|
||||
else nloop = 0;
|
||||
|
||||
|
@ -452,8 +461,10 @@ __forceinline int GIFPath::ParseTagQuick(GIF_PATH pathidx, const u8* pMem, u32 s
|
|||
incTag(8 * len, len);
|
||||
if (size & 1) { incTag(8, 1); }
|
||||
size /= 2;
|
||||
if(curreg != 0) DevCon.Warning("Oops Q %x", curreg);
|
||||
if(nloop = 0) curreg = 0;
|
||||
//if(curreg != 0 || (len % numregs) > 0) DevCon.Warning("Oops Q c %x n %x m %x r %x", curreg, nloop, (len % numregs), numregs);
|
||||
|
||||
|
||||
if(nloop == 0) curreg = 0;
|
||||
}
|
||||
break;
|
||||
case GIF_FLG_IMAGE:
|
||||
|
@ -635,19 +646,29 @@ __forceinline int GIFPath::ParseTag(GIF_PATH pathidx, const u8* pMem, u32 size)
|
|||
size *= 2;
|
||||
u32 len = aMin(size, (nloop * numregs)-curreg);
|
||||
|
||||
if(len < (nloop * numregs)-curreg)
|
||||
if(len < ((nloop * numregs)-curreg))
|
||||
{
|
||||
const int nloops_copied = len / numregs;
|
||||
const int regs_not_copied = len % numregs;
|
||||
|
||||
//DevCon.Warning("Hit it path %d", pathidx + 1);
|
||||
curreg += regs_not_copied;
|
||||
nloop -= len / numregs;
|
||||
nloop -= nloops_copied;
|
||||
|
||||
if(curreg >= numregs)
|
||||
{
|
||||
--nloop;
|
||||
curreg -= numregs;
|
||||
}
|
||||
}
|
||||
else nloop = 0;
|
||||
|
||||
incTag(8 * len, len);
|
||||
if (size & 1) { incTag(8, 1); }
|
||||
size /= 2;
|
||||
if(curreg != 0) DevCon.Warning("Oops Q %x", curreg);
|
||||
if(nloop = 0) curreg = 0;
|
||||
//if(curreg != 0 || (len % numregs) > 0) DevCon.Warning("Oops c %x n %x m %x r %x", curreg, nloop, (len % numregs), numregs);
|
||||
|
||||
if(nloop == 0) curreg = 0;
|
||||
}
|
||||
break;
|
||||
case GIF_FLG_IMAGE:
|
||||
|
|
Loading…
Reference in New Issue