Fix: rising from the grave as a zombie
When the hero is killed by a zombie, she is supposed to arise from the
grave as a zombie of a type matching her race. Commit 580c5a6 broke
this inadvertently -- done_in_by was passing gy.youmonst.data to
zombie_form() and relying on the old behavior where it attempted to
include the hero's race in is_elf, is_orc, etc if the permonst matched
the hero's role. Because this no longer works, zombie_form was only
returning PM_HUMAN_ZOMBIE when passed the role permonst of an
unpolymorphed hero. Use gu.urace.zombienum instead. This would have to
be a little more sophisticated (falling back to zombie_form() if Upolyd)
if a polymorphed hero with unchanging could die via done_in_by but
that's not currently possible as far as I can tell.
This commit is contained in:
@@ -781,8 +781,8 @@ done_in_by(struct monst *mtmp, int how)
|
||||
u.ugrave_arise = PM_WRAITH;
|
||||
else if (mptr->mlet == S_MUMMY && gu.urace.mummynum != NON_PM)
|
||||
u.ugrave_arise = gu.urace.mummynum;
|
||||
else if (zombie_maker(mtmp) && zombie_form(gy.youmonst.data) != NON_PM)
|
||||
u.ugrave_arise = zombie_form(gy.youmonst.data);
|
||||
else if (zombie_maker(mtmp) && gu.urace.zombienum != NON_PM)
|
||||
u.ugrave_arise = gu.urace.zombienum;
|
||||
else if (mptr->mlet == S_VAMPIRE && Race_if(PM_HUMAN))
|
||||
u.ugrave_arise = PM_VAMPIRE;
|
||||
else if (mptr == &mons[PM_GHOUL])
|
||||
|
||||
Reference in New Issue
Block a user