Make the "wall of water" stop thrown or kicked items

This commit is contained in:
Pasi Kallinen
2022-02-11 20:38:29 +02:00
parent cd797afd0e
commit 2ca8ac9a80
2 changed files with 7 additions and 0 deletions

View File

@@ -3459,6 +3459,12 @@ bhit(int ddx, int ddy, int range, /* direction and range */
typ = levl[g.bhitpos.x][g.bhitpos.y].typ;
/* WATER aka "wall of water" stops items */
if (typ == WATER) {
if (weapon == THROWN_WEAPON || weapon == KICKED_WEAPON)
break;
}
/* iron bars will block anything big enough and break some things */
if (weapon == THROWN_WEAPON || weapon == KICKED_WEAPON) {
if (obj->lamplit && !Blind)