fix #H2633 - turning to stone or slime while limbless
Michael's fix got here first, but didn't catch the green slime case.
This commit is contained in:
@@ -828,6 +828,7 @@ fix message given when part of a stack of items in a monster's inventory is
|
||||
being destroyed
|
||||
add "Boing!" message when hero zaps resistant monster with striking/force bolt
|
||||
adjust gaze reflection message when your scales are embedded in your skin
|
||||
adjust turning-to-stone or -slime messages when you have no limbs
|
||||
|
||||
|
||||
Platform- and/or Interface-Specific Fixes
|
||||
|
||||
@@ -26,13 +26,15 @@ static NEARDATA const char * const stoned_texts[] = {
|
||||
STATIC_OVL void
|
||||
stoned_dialogue()
|
||||
{
|
||||
char buf[BUFSZ];
|
||||
register long i = (Stoned & TIMEOUT);
|
||||
|
||||
if (i > 0L && i <= SIZE(stoned_texts)) {
|
||||
Strcpy(buf,stoned_texts[SIZE(stoned_texts) - i]);
|
||||
pline1(nolimbs(youmonst.data) ?
|
||||
strsubst(buf, "limbs", "extremities") : buf);
|
||||
char buf[BUFSZ];
|
||||
|
||||
Strcpy(buf, stoned_texts[SIZE(stoned_texts) - i]);
|
||||
if (nolimbs(youmonst.data) && strstri(buf, "limbs"))
|
||||
(void) strsubst(buf, "limbs", "extremities");
|
||||
pline1(buf);
|
||||
}
|
||||
switch ((int) i) {
|
||||
case 5: /* slowing down */
|
||||
@@ -149,18 +151,21 @@ slime_dialogue()
|
||||
{
|
||||
register long i = (Slimed & TIMEOUT) / 2L;
|
||||
|
||||
if (((Slimed & TIMEOUT) % 2L) && i >= 0L
|
||||
&& i < SIZE(slime_texts)) {
|
||||
const char *str = slime_texts[SIZE(slime_texts) - i - 1L];
|
||||
if (((Slimed & TIMEOUT) % 2L) && i >= 0L && i < SIZE(slime_texts)) {
|
||||
char buf[BUFSZ];
|
||||
|
||||
if (index(str, '%')) {
|
||||
Strcpy(buf, slime_texts[SIZE(slime_texts) - i - 1L]);
|
||||
if (nolimbs(youmonst.data) && strstri(buf, "limbs"))
|
||||
(void) strsubst(buf, "limbs", "extremities");
|
||||
|
||||
if (index(buf, '%')) {
|
||||
if (i == 4L) { /* "you are turning green" */
|
||||
if (!Blind) /* [what if you're already green?] */
|
||||
pline(str, hcolor(NH_GREEN));
|
||||
pline(buf, hcolor(NH_GREEN));
|
||||
} else
|
||||
pline(str, an(Hallucination ? rndmonnam() : "green slime"));
|
||||
pline(buf, an(Hallucination ? rndmonnam() : "green slime"));
|
||||
} else
|
||||
pline1(str);
|
||||
pline1(buf);
|
||||
}
|
||||
if (i == 3L) { /* limbs becoming oozy */
|
||||
HFast = 0L; /* lose intrinsic speed */
|
||||
|
||||
Reference in New Issue
Block a user