finally finished but not eating
Finally apply the patch sent by <Someone> in 11/2003 for slashem-Bugs-799278, updated to match the current code and handle additional cases. The fix is brute force: always ensure nomovemsg is set when nomul is called with a negative value. I also scanned the code for places manually setting multi negative, they all set nomovemsg. It would be nice to have a function that did the right thing, but there are several special cases and I was not feeling creative.
This commit is contained in:
@@ -102,6 +102,8 @@ avoid giving away wand type for near misses while blind
|
|||||||
avoid excessive repetition of "monsters are aware of your presence"
|
avoid excessive repetition of "monsters are aware of your presence"
|
||||||
monster's aggravation spell now affects meditating monsters
|
monster's aggravation spell now affects meditating monsters
|
||||||
busy pet won't miss out upon ascension
|
busy pet won't miss out upon ascension
|
||||||
|
fix various places that "finally finished" could be displayed after the hero
|
||||||
|
stopped doing something other than eating
|
||||||
|
|
||||||
|
|
||||||
Platform- and/or Interface-Specific Fixes
|
Platform- and/or Interface-Specific Fixes
|
||||||
|
|||||||
@@ -704,6 +704,7 @@ struct obj *obj;
|
|||||||
"Yow! The mirror stares back!" :
|
"Yow! The mirror stares back!" :
|
||||||
"Yikes! You've frozen yourself!");
|
"Yikes! You've frozen yourself!");
|
||||||
nomul(-rnd((MAXULEV+6) - u.ulevel));
|
nomul(-rnd((MAXULEV+6) - u.ulevel));
|
||||||
|
nomovemsg = 0;
|
||||||
} else You("stiffen momentarily under your gaze.");
|
} else You("stiffen momentarily under your gaze.");
|
||||||
} else if (youmonst.data->mlet == S_VAMPIRE)
|
} else if (youmonst.data->mlet == S_VAMPIRE)
|
||||||
You("don't have a reflection.");
|
You("don't have a reflection.");
|
||||||
|
|||||||
@@ -633,6 +633,7 @@ hurtle(dx, dy, range, verbose)
|
|||||||
if(!range || (!dx && !dy) || u.ustuck) return; /* paranoia */
|
if(!range || (!dx && !dy) || u.ustuck) return; /* paranoia */
|
||||||
|
|
||||||
nomul(-range);
|
nomul(-range);
|
||||||
|
nomovemsg = 0;
|
||||||
if (verbose)
|
if (verbose)
|
||||||
You("%s in the opposite direction.", range > 1 ? "hurtle" : "float");
|
You("%s in the opposite direction.", range > 1 ? "hurtle" : "float");
|
||||||
/* if we're in the midst of shooting multiple projectiles, stop */
|
/* if we're in the midst of shooting multiple projectiles, stop */
|
||||||
|
|||||||
@@ -2590,6 +2590,7 @@ vomit() /* A good idea from David Neves */
|
|||||||
{
|
{
|
||||||
make_sick(0L, (char *) 0, TRUE, SICK_VOMITABLE);
|
make_sick(0L, (char *) 0, TRUE, SICK_VOMITABLE);
|
||||||
nomul(-2);
|
nomul(-2);
|
||||||
|
nomovemsg = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
|
|||||||
@@ -606,6 +606,7 @@ int spellnum;
|
|||||||
if (Half_spell_damage) dmg = (dmg + 1) / 2;
|
if (Half_spell_damage) dmg = (dmg + 1) / 2;
|
||||||
nomul(-dmg);
|
nomul(-dmg);
|
||||||
}
|
}
|
||||||
|
nomovemsg = 0;
|
||||||
dmg = 0;
|
dmg = 0;
|
||||||
break;
|
break;
|
||||||
case CLC_CONFUSE_YOU:
|
case CLC_CONFUSE_YOU:
|
||||||
|
|||||||
@@ -1043,6 +1043,7 @@ dogaze()
|
|||||||
-d((int)mtmp->m_lev+1,
|
-d((int)mtmp->m_lev+1,
|
||||||
(int)mtmp->data->mattk[0].damd)
|
(int)mtmp->data->mattk[0].damd)
|
||||||
: -200);
|
: -200);
|
||||||
|
nomovemsg = 0;
|
||||||
return 1;
|
return 1;
|
||||||
} else
|
} else
|
||||||
You("stiffen momentarily under %s gaze.",
|
You("stiffen momentarily under %s gaze.",
|
||||||
|
|||||||
@@ -1207,6 +1207,7 @@ dosacrifice()
|
|||||||
dmon->mpeaceful = TRUE;
|
dmon->mpeaceful = TRUE;
|
||||||
You("are terrified, and unable to move.");
|
You("are terrified, and unable to move.");
|
||||||
nomul(-3);
|
nomul(-3);
|
||||||
|
nomovemsg = 0;
|
||||||
} else pline_The("%s.", demonless_msg);
|
} else pline_The("%s.", demonless_msg);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1737,6 +1738,7 @@ doturn()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
nomul(-5);
|
nomul(-5);
|
||||||
|
nomovemsg = 0;
|
||||||
return(1);
|
return(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -619,6 +619,7 @@ register struct monst *mtmp;
|
|||||||
pline("%s rattles noisily.", Monnam(mtmp));
|
pline("%s rattles noisily.", Monnam(mtmp));
|
||||||
You("freeze for a moment.");
|
You("freeze for a moment.");
|
||||||
nomul(-2);
|
nomul(-2);
|
||||||
|
nomovemsg = 0;
|
||||||
break;
|
break;
|
||||||
case MS_LAUGH:
|
case MS_LAUGH:
|
||||||
{
|
{
|
||||||
|
|||||||
+5
-2
@@ -326,7 +326,8 @@ learn()
|
|||||||
(void) confused_book(context.spbook.book);
|
(void) confused_book(context.spbook.book);
|
||||||
context.spbook.book = 0; /* no longer studying */
|
context.spbook.book = 0; /* no longer studying */
|
||||||
context.spbook.o_id = 0;
|
context.spbook.o_id = 0;
|
||||||
nomul(context.spbook.delay); /* remaining delay is uninterrupted */
|
nomul(context.spbook.delay); /* remaining delay is uninterrupted */
|
||||||
|
nomovemsg = 0;
|
||||||
context.spbook.delay = 0;
|
context.spbook.delay = 0;
|
||||||
return(0);
|
return(0);
|
||||||
}
|
}
|
||||||
@@ -466,7 +467,8 @@ register struct obj *spellbook;
|
|||||||
if (too_hard) {
|
if (too_hard) {
|
||||||
boolean gone = cursed_book(spellbook);
|
boolean gone = cursed_book(spellbook);
|
||||||
|
|
||||||
nomul(context.spbook.delay); /* study time */
|
nomul(context.spbook.delay); /* study time */
|
||||||
|
nomovemsg = 0;
|
||||||
context.spbook.delay = 0;
|
context.spbook.delay = 0;
|
||||||
if(gone || !rn2(3)) {
|
if(gone || !rn2(3)) {
|
||||||
if (!gone) pline_The("spellbook crumbles to dust!");
|
if (!gone) pline_The("spellbook crumbles to dust!");
|
||||||
@@ -482,6 +484,7 @@ register struct obj *spellbook;
|
|||||||
spellbook->in_use = FALSE;
|
spellbook->in_use = FALSE;
|
||||||
}
|
}
|
||||||
nomul(context.spbook.delay);
|
nomul(context.spbook.delay);
|
||||||
|
nomovemsg = 0;
|
||||||
context.spbook.delay = 0;
|
context.spbook.delay = 0;
|
||||||
return(1);
|
return(1);
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-2
@@ -391,12 +391,12 @@ gotobj:
|
|||||||
named++;
|
named++;
|
||||||
/* the following is to set multi for later on */
|
/* the following is to set multi for later on */
|
||||||
nomul(-armordelay);
|
nomul(-armordelay);
|
||||||
|
nomovemsg = 0;
|
||||||
remove_worn_item(otmp, TRUE);
|
remove_worn_item(otmp, TRUE);
|
||||||
otmp->cursed = curssv;
|
otmp->cursed = curssv;
|
||||||
if(multi < 0){
|
if(multi < 0) {
|
||||||
/*
|
/*
|
||||||
multi = 0;
|
multi = 0;
|
||||||
nomovemsg = 0;
|
|
||||||
afternmv = 0;
|
afternmv = 0;
|
||||||
*/
|
*/
|
||||||
stealoid = otmp->o_id;
|
stealoid = otmp->o_id;
|
||||||
|
|||||||
@@ -44,6 +44,7 @@ stoned_dialogue()
|
|||||||
case 3: /* limbs turned to stone */
|
case 3: /* limbs turned to stone */
|
||||||
stop_occupation();
|
stop_occupation();
|
||||||
nomul(-3); /* can't move anymore */
|
nomul(-3); /* can't move anymore */
|
||||||
|
nomovemsg = 0;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
@@ -1239,6 +1240,7 @@ do_storms()
|
|||||||
if(!u.uinvulnerable) {
|
if(!u.uinvulnerable) {
|
||||||
stop_occupation();
|
stop_occupation();
|
||||||
nomul(-3);
|
nomul(-3);
|
||||||
|
nomovemsg = 0;
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
You_hear("a rumbling noise.");
|
You_hear("a rumbling noise.");
|
||||||
|
|||||||
@@ -2317,6 +2317,7 @@ boolean wep_was_destroyed;
|
|||||||
You("are frozen by %s gaze!",
|
You("are frozen by %s gaze!",
|
||||||
s_suffix(mon_nam(mon)));
|
s_suffix(mon_nam(mon)));
|
||||||
nomul((ACURR(A_WIS) > 12 || rn2(4)) ? -tmp : -127);
|
nomul((ACURR(A_WIS) > 12 || rn2(4)) ? -tmp : -127);
|
||||||
|
nomovemsg = 0;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
pline("%s cannot defend itself.",
|
pline("%s cannot defend itself.",
|
||||||
|
|||||||
Reference in New Issue
Block a user