From 9b1b13ef1d16678a0cfbb2ab0883707701867d32 Mon Sep 17 00:00:00 2001 From: cohrs Date: Thu, 28 Nov 2002 20:44:54 +0000 Subject: [PATCH] fix up several death messages reported several incorrect death messages 1) "petrified by deliberately gazing at Medusa's hideous countenance" is too long and won't fit on the tombstone. I reworded it, which also better reflects that Medusa's gaze is really an active attack. 2) "killed by war hammer named Mjollnir" for partly identified Mjollnir now says "killed by a war hammer named Mjollnir". 3) "using a magical horn on himself" was missing the "killed by" prefix 4) there were supposedly cases the the a/an article was missing after being killed by a monster. I didn't see where this was occuring (eg AoLS resets killer_format before it returns), but now done_in_by always resets killer_format, which should address any such cases. --- doc/fixes34.1 | 1 + src/dothrow.c | 3 ++- src/end.c | 1 + src/music.c | 2 +- src/polyself.c | 3 +-- 5 files changed, 6 insertions(+), 4 deletions(-) diff --git a/doc/fixes34.1 b/doc/fixes34.1 index 0f434b76e..3ffb6eeeb 100644 --- a/doc/fixes34.1 +++ b/doc/fixes34.1 @@ -315,6 +315,7 @@ only hard helmets protect against falling piercers don't crash teleporting out of a monster while engulfed, punished but not carrying the ball web breaking should consider steed strength and other characteristics +various missing or inappropriate "killed by" death messages Platform- and/or Interface-Specific Fixes diff --git a/src/dothrow.c b/src/dothrow.c index 755e0f794..f93600395 100644 --- a/src/dothrow.c +++ b/src/dothrow.c @@ -1006,7 +1006,8 @@ boolean twoweap; /* used to restore twoweapon mode if wielded weapon returns */ body_part(ARM)); (void) artifact_hit((struct monst *)0, &youmonst, obj, &dmg, 0); - losehp(dmg, xname(obj), KILLED_BY); + losehp(dmg, xname(obj), + obj_is_pname(obj) ? KILLED_BY : KILLED_BY_AN); } if (ship_object(obj, u.ux, u.uy, FALSE)) return; diff --git a/src/end.c b/src/end.c index 476a9bfac..7d677e53d 100644 --- a/src/end.c +++ b/src/end.c @@ -190,6 +190,7 @@ register struct monst *mtmp; You("die..."); mark_synch(); /* flush buffered screen output */ buf[0] = '\0'; + killer_format = KILLED_BY_AN; /* "killed by the high priest of Crom" is okay, "killed by the high priest" alone isn't */ if ((mtmp->data->geno & G_UNIQ) != 0 && !(mtmp->data == &mons[PM_HIGH_PRIEST] && !mtmp->ispriest)) { diff --git a/src/music.c b/src/music.c index 6cdb54fb9..632b34cd6 100644 --- a/src/music.c +++ b/src/music.c @@ -409,7 +409,7 @@ struct obj *instr; if ((damage = zapyourself(instr, TRUE)) != 0) { char buf[BUFSZ]; Sprintf(buf, "using a magical horn on %sself", uhim()); - losehp(damage, buf, NO_KILLER_PREFIX); + losehp(damage, buf, KILLED_BY); } } else { buzz((instr->otyp == FROST_HORN) ? AD_COLD-1 : AD_FIRE-1, diff --git a/src/polyself.c b/src/polyself.c index 06f7fce68..20bd7e099 100644 --- a/src/polyself.c +++ b/src/polyself.c @@ -1020,8 +1020,7 @@ dogaze() /* as if gazing at a sleeping anything is fruitful... */ You("turn to stone..."); killer_format = KILLED_BY; - killer = - "deliberately gazing at Medusa's hideous countenance"; + killer = "deliberately meeting Medusa's gaze"; done(STONING); } }