hero-as-gremlin enhancements
When hero is poly'd into a gremlin, using #monster at a fountain location will clone a gremlin pet. Do the same at a pool location (might not match the movie but if not, most likely because the situation never came up). Also, do the same for #sit at either fountain or pool.
This commit is contained in:
@@ -915,8 +915,13 @@ domonability(void)
|
|||||||
if (IS_FOUNTAIN(levl[u.ux][u.uy].typ)) {
|
if (IS_FOUNTAIN(levl[u.ux][u.uy].typ)) {
|
||||||
if (split_mon(&gy.youmonst, (struct monst *) 0))
|
if (split_mon(&gy.youmonst, (struct monst *) 0))
|
||||||
dryup(u.ux, u.uy, TRUE);
|
dryup(u.ux, u.uy, TRUE);
|
||||||
} else
|
} else if (is_pool(u.ux, u.uy)) {
|
||||||
|
/* is_pool: might be wearing water walking boots or amulet of
|
||||||
|
magical breathing */
|
||||||
|
(void) split_mon(&gy.youmonst, (struct monst *) 0);
|
||||||
|
} else {
|
||||||
There("is no fountain here.");
|
There("is no fountain here.");
|
||||||
|
}
|
||||||
} else if (is_unicorn(uptr)) {
|
} else if (is_unicorn(uptr)) {
|
||||||
use_unicorn_horn((struct obj **) 0);
|
use_unicorn_horn((struct obj **) 0);
|
||||||
return ECMD_TIME;
|
return ECMD_TIME;
|
||||||
|
|||||||
@@ -297,6 +297,9 @@ dosit(void)
|
|||||||
return ECMD_OK;
|
return ECMD_OK;
|
||||||
} else if (is_pool(u.ux, u.uy) && !Underwater) { /* water walking */
|
} else if (is_pool(u.ux, u.uy) && !Underwater) { /* water walking */
|
||||||
goto in_water;
|
goto in_water;
|
||||||
|
} else if (Upolyd && u.umonnum == PM_GREMLIN
|
||||||
|
&& (levl[u.ux][u.uy].typ == FOUNTAIN || is_pool(u.ux, u.uy))) {
|
||||||
|
goto in_water;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (OBJ_AT(u.ux, u.uy)
|
if (OBJ_AT(u.ux, u.uy)
|
||||||
@@ -373,10 +376,18 @@ dosit(void)
|
|||||||
} else if (is_pool(u.ux, u.uy) && !eggs_in_water(gy.youmonst.data)) {
|
} else if (is_pool(u.ux, u.uy) && !eggs_in_water(gy.youmonst.data)) {
|
||||||
in_water:
|
in_water:
|
||||||
You("sit in the %s.", hliquid("water"));
|
You("sit in the %s.", hliquid("water"));
|
||||||
if (!rn2(10) && uarm)
|
if (Upolyd && u.umonnum == PM_GREMLIN) {
|
||||||
(void) water_damage(uarm, "armor", TRUE);
|
if (split_mon(&gy.youmonst, (struct monst *) 0)) {
|
||||||
if (!rn2(10) && uarmf && uarmf->otyp != WATER_WALKING_BOOTS)
|
if (levl[u.ux][u.uy].typ == FOUNTAIN)
|
||||||
(void) water_damage(uarm, "armor", TRUE);
|
dryup(u.ux, u.uy, TRUE);
|
||||||
|
}
|
||||||
|
/* splitting--or failing to do so--protects gear from the water */
|
||||||
|
} else {
|
||||||
|
if (!rn2(10) && uarm)
|
||||||
|
(void) water_damage(uarm, "armor", TRUE);
|
||||||
|
if (!rn2(10) && uarmf && uarmf->otyp != WATER_WALKING_BOOTS)
|
||||||
|
(void) water_damage(uarm, "armor", TRUE);
|
||||||
|
}
|
||||||
} else if (IS_SINK(typ)) {
|
} else if (IS_SINK(typ)) {
|
||||||
You(sit_message, defsyms[S_sink].explanation);
|
You(sit_message, defsyms[S_sink].explanation);
|
||||||
Your("%s gets wet.",
|
Your("%s gets wet.",
|
||||||
|
|||||||
Reference in New Issue
Block a user