From 19c702a60843c0c2dc41409ae0a9c92b31e30def Mon Sep 17 00:00:00 2001 From: Edoardo Prezioso Date: Wed, 9 Sep 2015 21:26:44 +0200 Subject: [PATCH] - Fixed a crash when a player dies in damage floors. --- src/p_interaction.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/p_interaction.cpp b/src/p_interaction.cpp index a0b1ddbc12..603535b7c2 100644 --- a/src/p_interaction.cpp +++ b/src/p_interaction.cpp @@ -184,7 +184,6 @@ void ClientObituary (AActor *self, AActor *inflictor, AActor *attacker, int dmgf const char *message; const char *messagename; char gendermessage[1024]; - bool friendly; int gender; // No obituaries for non-players, voodoo dolls or when not wanted @@ -197,8 +196,6 @@ void ClientObituary (AActor *self, AActor *inflictor, AActor *attacker, int dmgf if (inflictor && inflictor->player && inflictor->player->mo != inflictor) MeansOfDeath = NAME_None; - friendly = (self->player != attacker->player && self->IsTeammate(attacker)); - mod = MeansOfDeath; message = NULL; messagename = NULL; @@ -266,7 +263,7 @@ void ClientObituary (AActor *self, AActor *inflictor, AActor *attacker, int dmgf if (message == NULL && attacker != NULL && attacker->player != NULL) { - if (friendly) + if (self->player != attacker->player && self->IsTeammate(attacker)) { self = attacker; gender = self->player->userinfo.GetGender();