Add exhumed collision emulation

This commit is contained in:
nukeykt 2019-09-23 04:09:50 +09:00 committed by Christoph Oelckers
parent 721ab04da1
commit e9d2a25f7f
3 changed files with 6 additions and 1 deletions

View file

@ -509,6 +509,8 @@ void InstallEngine()
LoadPaletteLookups(); LoadPaletteLookups();
MyLoadPalette(); MyLoadPalette();
enginecompatibility_mode = ENGINECOMPATIBILITY_19950829;
} }
void RemoveEngine() void RemoveEngine()

View file

@ -1177,7 +1177,7 @@ void FuncPlayer(int pA, int nDamage, int nRun)
} }
// loc_1A6E4 // loc_1A6E4
if (!inside(sprite[nPlayerSprite].x, sprite[nPlayerSprite].y, sprite[nPlayerSprite].sectnum)) if (inside(sprite[nPlayerSprite].x, sprite[nPlayerSprite].y, sprite[nPlayerSprite].sectnum) != 1)
{ {
mychangespritesect(nPlayerSprite, spr_sectnum); mychangespritesect(nPlayerSprite, spr_sectnum);

View file

@ -1051,6 +1051,9 @@ void FuncQueenHead(int a, int nDamage, int nRun)
sprite[nSprite].cstat = 0x8000; sprite[nSprite].cstat = 0x8000;
// DEMO-TODO: in disassembly angle was used without masking and thus causing OOB issue.
// This behavior probably would be needed emulated for demo compatibility
// int dx = sintable[RandomSize(11) & kAngleMask) + 512] << 10;
int dx = Sin((RandomSize(11) & kAngleMask) + 512) << 10; int dx = Sin((RandomSize(11) & kAngleMask) + 512) << 10;
int dy = Sin(RandomSize(11) & kAngleMask) << 10; int dy = Sin(RandomSize(11) & kAngleMask) << 10;
int dz = (RandomSize(5) - RandomSize(5)) << 7; int dz = (RandomSize(5) - RandomSize(5)) << 7;