From cd91d0630b4aac8b502713715b29a696ece5d765 Mon Sep 17 00:00:00 2001 From: PatR Date: Sat, 30 Dec 2023 17:10:39 -0800 Subject: [PATCH] github issue #1180 - humans and murder Issue reported by Umbire: reviving a human corpse into a human monster and then killing it entails murder penalty even when it is hostile. This is probably a non-issue. Human monsters tend to not leave human corpses, they leave shopkeeper corpses or sergeant corpses and so forth. Most human corpses created in normal play have montraits attached and revive as a zombie, mummy, or vampire rather than as a human. This doesn't attempt to be clever, it just treats PM_HUMAN like role monsters, not subject to 'murder'. Closes #1180 --- src/mon.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/mon.c b/src/mon.c index 348c9b982..cb9e7b313 100644 --- a/src/mon.c +++ b/src/mon.c @@ -3339,10 +3339,18 @@ xkilled( newsym(x, y); cleanup: - /* punish bad behavior */ + /* + * Punish bad behavior. + */ if (is_human(mdat) && (!always_hostile(mdat) && mtmp->malign <= 0) + /* exclude role monsters */ && (mndx < PM_ARCHEOLOGIST || mndx > PM_WIZARD) + /* exclude plain "human", which isn't flagged as always hostile; + it is rare and most likely to occur as the result of resurrecting + a corpse or animating a statue and usually will be hostile */ + && mndx != PM_HUMAN + /* only applicable if hero is lawful or neutral */ && u.ualign.type != A_CHAOTIC) { HTelepat &= ~INTRINSIC; change_luck(-2);