follow-up for dig_check changes

Use the is_hole() macro to cover off holes and trapdoors.
This commit is contained in:
nhmall
2024-07-23 16:22:30 -04:00
parent b08fb9fb93
commit faca234055

View File

@@ -234,7 +234,7 @@ dig_check(struct monst *madeby, coordxy x, coordxy y)
return DIGCHECK_FAIL_UNDESTROYABLETRAP;
} else if (!Can_dig_down(&u.uz) && !levl[x][y].candig) {
if (ttmp) {
if (ttmp->ttyp != HOLE && !is_pit(ttmp->ttyp))
if (!is_hole(ttmp->ttyp) && !is_pit(ttmp->ttyp))
return DIGCHECK_PASSED_DESTROY_TRAP;
else
return DIGCHECK_FAIL_CANTDIG;