Correct assertions in ProcessMonsters

This commit is contained in:
Anders Jenbo 2021-07-03 03:53:32 +02:00
commit d7a86330c6

View file

@ -4398,12 +4398,12 @@ void ProcessMonsters()
int menemy;
if ((Monst->_mFlags & MFLAG_TARGETS_MONSTER) != 0) {
menemy = Monst->_menemy;
assurance((DWORD)menemy < MAXMONSTERS, Monst);
assurance((DWORD)menemy < MAXMONSTERS, menemy);
Monst->position.last = monster[Monst->_menemy].position.future;
Monst->enemyPosition = Monst->position.last;
} else {
menemy = Monst->_menemy;
assurance((DWORD)menemy < MAX_PLRS, Monst);
assurance((DWORD)menemy < MAX_PLRS, menemy);
Monst->enemyPosition = plr[Monst->_menemy].position.future;
if ((dFlags[mx][my] & BFLAG_VISIBLE) != 0) {
Monst->_msquelch = UINT8_MAX;