From 0055130494d636fe923ceb9938e4bd1d801ec47f Mon Sep 17 00:00:00 2001 From: zeromus Date: Sun, 25 Jan 2009 22:11:50 +0000 Subject: [PATCH] readme crazymax: matrix stack "size" is 31 for 32 entry stack (silly, i know) so your overrun check was wrong. --- desmume/src/gfx3d.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desmume/src/gfx3d.cpp b/desmume/src/gfx3d.cpp index a23102ff7..87e86acf4 100644 --- a/desmume/src/gfx3d.cpp +++ b/desmume/src/gfx3d.cpp @@ -407,7 +407,7 @@ void gfx3d_glPushMatrix() //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode short mymode = (mode==1?2:mode); - if (mtxStack[mymode].position >= mtxStack[mymode].size) + if (mtxStack[mymode].position > mtxStack[mymode].size) { gxstat |= (1<<15); T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat);