fix github issue #1186 - eating Medusa's corpse

and having temporary stoning resistance timeout before finishing.

Issue reported by Umbire:  hero was able to finish eating Medusa's
corpse safely after getting the message about no longer being
protected against stoning that is given when temporary resistance
times out.

The eating code was extending temporary resistance--when eating
something protected by such--to avoid just that.  I thought this
was probably a message sequencing situation but it turns out that
the code was using touch_petrifies() to test the meal.  It should
use flesh_petrifies() instead; Medusa doesn't pass touch_petrifies().

I didn't figure that out until after rewriting how the duration is
extended.  The old way probably would have worked as desired with
the revised petrify test but I'm checking in the new version anyway.

Fixes #1186
This commit is contained in:
PatR
2023-12-23 17:38:05 -08:00
parent 35eb289cc3
commit 05cf948007
4 changed files with 58 additions and 25 deletions

View File

@@ -1811,6 +1811,11 @@ autopickup while levitating shares code with 'mention_decor'; after being told
about ice covered by an object, moving over some other object later
when mention_decor is Off could give "you are back on solid ground"
long after leaving the ice
duration of temporary stoning resistance would be extended while eating a
cockatrice corpse, as intended, but not while eating Medusa's corpse
so if it timed out during the meal, player got the message about hero
no longer being protected against stoning but was able to finish the
meal safely
Fixes to 3.7.0-x Platform and/or Interface Problems Exposed Via git Repository