Revisión | b00c03193dc77ef06c2a1718c89e7e179f7d1e8b (tree) |
---|---|
Tiempo | 2021-05-17 03:42:37 |
Autor | Adam Kaminski <kaminskiadam9@gmai...> |
Commiter | Adam Kaminski |
Removed unnecessary, convoluted code in ClientObituary.
@@ -215,10 +215,6 @@ | ||
215 | 215 | char gendermessage[1024]; |
216 | 216 | bool friendly; |
217 | 217 | int gender; |
218 | - // We enough characters for the player's name, the terminating zero, and 4 characters | |
219 | - // to strip the color codes (I actually believe it's 3, but let's play it safe). | |
220 | - char szAttacker[MAXPLAYERNAME+1+4]; | |
221 | - char szVictim[MAXPLAYERNAME+1+4]; | |
222 | 218 | |
223 | 219 | // No obituaries for non-players, voodoo dolls or when not wanted |
224 | 220 | // [AK] Added a check if the player was forced as a dead spectator through ACS. |
@@ -366,20 +362,8 @@ | ||
366 | 362 | message = GStrings("OB_DEFAULT"); |
367 | 363 | } |
368 | 364 | |
369 | - // [BC] Stop the color codes after we display a name in the obituary string. | |
370 | - if ( attacker && attacker->player ) | |
371 | - sprintf( szAttacker, "%s", attacker->player->userinfo.GetName() ); | |
372 | - else | |
373 | - szAttacker[0] = 0; | |
374 | - | |
375 | - if ( self && self->player ) | |
376 | - sprintf( szVictim, "%s", self->player->userinfo.GetName() ); | |
377 | - else | |
378 | - szVictim[0] = 0; | |
379 | - | |
380 | 365 | SexMessage (message, gendermessage, gender, |
381 | - szVictim[0] ? szVictim : self->player->userinfo.GetName(), | |
382 | - szAttacker[0] ? szAttacker : attacker->player->userinfo.GetName()); | |
366 | + self->player->userinfo.GetName(), attacker->player->userinfo.GetName()); | |
383 | 367 | |
384 | 368 | // [AK] Format our message so color codes can appear. |
385 | 369 | V_ColorizeString( gendermessage ); |