- Being killed by a voodoo doll now has its own obituary, rather than trying to come up with one

by treating it as a real player.

SVN r3574 (trunk)
This commit is contained in:
Randy Heit 2012-04-19 04:03:42 +00:00
parent b036ef63e9
commit b94607dc7e
2 changed files with 8 additions and 1 deletions

View file

@ -192,7 +192,7 @@ void ClientObituary (AActor *self, AActor *inflictor, AActor *attacker)
gender = self->player->userinfo.gender;
// Treat voodoo dolls as unknown deaths
if (inflictor && inflictor->player == self->player)
if (inflictor && inflictor->player && inflictor->player->mo != inflictor)
MeansOfDeath = NAME_None;
if (multiplayer && !deathmatch)
@ -228,6 +228,12 @@ void ClientObituary (AActor *self, AActor *inflictor, AActor *attacker)
case NAME_Fire: if (attacker == NULL) messagename = "OB_LAVA"; break;
}
// Check for being killed by a voodoo doll.
if (inflictor && inflictor->player && inflictor->player->mo != inflictor)
{
messagename = "OB_VOODOO";
}
if (messagename != NULL)
message = GStrings(messagename);

View file

@ -620,6 +620,7 @@ OB_R_SPLASH = "%o should have stood back.";
OB_ROCKET = "%o should have stood back.";
OB_KILLEDSELF = "%o killed %hself.";
OB_VOODOO = "%o was kill by the power of voodoo.";
OB_STEALTHBABY = "%o thought %g saw an arachnotron.";
OB_STEALTHVILE = "%o thought %g saw an archvile.";
OB_STEALTHBARON = "%o thought %g saw a Baron of Hell.";