diff --git a/source/exhumed/src/enginesubs.cpp b/source/exhumed/src/enginesubs.cpp index c344afd47..0eadd809e 100644 --- a/source/exhumed/src/enginesubs.cpp +++ b/source/exhumed/src/enginesubs.cpp @@ -15,10 +15,29 @@ void overwritesprite(int thex, int they, short tilenum, signed char shade, char (char)(((flags & 1 ^ 1) << 4) + (flags & 2) + ((flags & 4) >> 2) + ((flags & 16) >> 2) ^ ((flags & 8) >> 1)), windowx1, windowy1, windowx2, windowy2); #endif - + // no animation + uint8_t animbak = picanm[tilenum].sf; + picanm[tilenum].sf = 0; + int offx = 0, offy = 0; + if (stat & 1) + { + offx -= tilesiz[tilenum].x>>1; + if (stat & 8) + offx += picanm[tilenum].xofs; + else + offx -= picanm[tilenum].xofs; + offy -= (tilesiz[tilenum].y>>1)+picanm[tilenum].yofs; + } + if (stat&8) + offx += tilesiz[tilenum].x; + if (stat&16) + offy += tilesiz[tilenum].y; + thex += offx; + they += offy; rotatesprite(thex << 16, they << 16, 65536L, (stat & 8) << 7, tilenum, shade, dapalnum, - (((stat & 1) ^ 1) << 4) + (stat & 2) + ((stat & 4) >> 2) + (((stat & 16) >> 2) ^ ((stat & 8) >> 1)), + 16 + (stat & 2) + ((stat & 4) >> 2) + (((stat & 16) >> 2) ^ ((stat & 8) >> 1)), windowxy1.x, windowxy1.y, windowxy2.x, windowxy2.y); + picanm[tilenum].sf = animbak; } void permanentwritesprite(int thex, int they, short tilenum, signed char shade, int cx1, int cy1, int cx2, int cy2, char dapalnum) diff --git a/source/exhumed/src/exhumed.cpp b/source/exhumed/src/exhumed.cpp index f3e3f7bbd..365441b66 100644 --- a/source/exhumed/src/exhumed.cpp +++ b/source/exhumed/src/exhumed.cpp @@ -703,9 +703,9 @@ void faketimerhandler() { if ((totalclock < ototalclock + 1) || bInMove) return; - ototalclock += 1; + ototalclock++; - if (moveframes < 4) + if (!(ototalclock&3) && moveframes < 4) moveframes++; PlayerInterruptKeys(); diff --git a/source/exhumed/src/menu.cpp b/source/exhumed/src/menu.cpp index c98b88f35..2cfc7393e 100644 --- a/source/exhumed/src/menu.cpp +++ b/source/exhumed/src/menu.cpp @@ -513,7 +513,7 @@ void menu_DoPlasma() } // draw the fire urn/lamp thingies - int dword_9AB5F = ((totalclock - ((totalclock >> 31) + 16 * (totalclock >> 31))) >> 4) & 3; + int dword_9AB5F = (totalclock/16) & 3; overwritesprite(50, 150, kTile3512 + dword_9AB5F, 0, 3, kPalNormal); overwritesprite(270, 150, kTile3512 + ((dword_9AB5F + 2) & 3), 0, 3, kPalNormal); diff --git a/source/exhumed/src/sequence.cpp b/source/exhumed/src/sequence.cpp index 61941ba2e..098327d77 100644 --- a/source/exhumed/src/sequence.cpp +++ b/source/exhumed/src/sequence.cpp @@ -343,19 +343,6 @@ void seq_DrawStatusSequence(short nSequence, uint16_t edx, short ebx) laststatusx = ChunkXpos[nFrameBase] + 160; laststatusy = ChunkYpos[nFrameBase] + 100 + ebx; - int thex = laststatusx; - int they = laststatusy; - - if (laststatusx >= 155 && laststatusx <= 162) { - laststatusx = 159; - } - - // TEMP - if (laststatusy == 188 && laststatusx == 159) - laststatusy = 189; - - - short chunkFlag = ChunkFlag[nFrameBase]; if (chunkFlag & 1) {