* it's gone for good... If the destination is not a pool, returns FALSE.
*/
boolean
-boulder_hits_pool(struct obj *otmp, coordxy rx, coordxy ry, boolean pushing)
+boulder_hits_pool(
+ struct obj *otmp,
+ coordxy rx, coordxy ry,
+ boolean pushing)
{
if (!otmp || otmp->otyp != BOULDER) {
impossible("Not a boulder?");
- } else if (!Is_waterlevel(&u.uz) && is_pool_or_lava(rx, ry)) {
+ } else if (is_pool_or_lava(rx, ry)) {
boolean lava = is_lava(rx, ry), fills_up;
const char *what = waterbody_name(rx, ry);
schar ltyp = levl[rx][ry].typ;
int chance = rn2(10); /* water: 90%; lava: 10% */
struct monst *mtmp;
- fills_up = lava ? chance == 0 : chance != 0;
+ fills_up = Is_waterlevel(&u.uz) ? FALSE
+ : (ltyp == WATER) ? (chance < 5) /* wall of water */
+ : lava ? (chance == 0) : (chance != 0);
if (fills_up) {
struct trap *ttmp = t_at(rx, ry);
if (ltyp == DRAWBRIDGE_UP) {
levl[rx][ry].drawbridgemask &= ~DB_UNDER; /* clear lava */
levl[rx][ry].drawbridgemask |= DB_FLOOR;
- } else
+ } else {
levl[rx][ry].typ = ROOM, levl[rx][ry].flags = 0;
-
+ }
/* 3.7: normally DEADMONSTER() is used when traversing the fmon
list--dead monsters usually aren't still at specific map
locations; however, if ice melts causing a giant to drown,
There("is a large splash as %s %s the %s.",
the(xname(otmp)), fills_up ? "fills" : "falls into",
what);
- } else if (!Deaf)
+ } else if (!Deaf) {
You_hear("a%s splash.", lava ? " sizzling" : "");
+ }
wake_nearto(rx, ry, 40);
}
You("find yourself on dry land again!");
} else if (lava && next2u(rx, ry)) {
int dmg;
+
You("are hit by molten %s%c",
hliquid("lava"), Fire_resistance ? '.' : '!');
burn_away_slime();