attempt to resolve issue #1368

Resolve #1368
This commit is contained in:
nhmall
2025-01-24 17:06:17 -05:00
parent c9abc92dd7
commit 02102de396
3 changed files with 14 additions and 3 deletions

View File

@@ -365,6 +365,10 @@ restmon(NHFILE *nhfp, struct monst *mtmp)
newedog(mtmp);
if (nhfp->structlevel)
Mread(nhfp->fd, EDOG(mtmp), sizeof (struct edog));
/* sanity check to prevent rn2(0) */
if (EDOG(mtmp)->apport <= 0) {
EDOG(mtmp)->apport = 1;
}
}
/* mcorpsenm - obj->corpsenm for mimic posing as corpse or
statue (inline int rather than pointer to something) */