mirror of
https://github.com/unknownworlds/NS.git
synced 2024-11-22 20:51:36 +00:00
o Fixed bug where the two first letters of a weapon in the kill message would get truncated.
o Fixed bug where it would not find the correct kill sprite. git-svn-id: https://unknownworlds.svn.cloudforge.com/ns1@120 67975925-1194-0748-b3d5-c16f83f1a3a1
This commit is contained in:
parent
f248e509e6
commit
10b9fde0f5
1 changed files with 6 additions and 4 deletions
|
@ -254,7 +254,9 @@ int CHudDeathNotice :: MsgFunc_DeathMsg( const char *pszName, int iSize, void *p
|
|||
}
|
||||
|
||||
// Find the sprite in the list
|
||||
int spr = gHUD.GetSpriteIndex( killed_with.c_str() );
|
||||
char killed_with_spritename[32];
|
||||
sprintf(killed_with_spritename, "d_%s", killed_with.c_str());
|
||||
int spr = gHUD.GetSpriteIndex( killed_with_spritename );
|
||||
|
||||
rgDeathNoticeList[i].iId = spr;
|
||||
|
||||
|
@ -275,7 +277,7 @@ int CHudDeathNotice :: MsgFunc_DeathMsg( const char *pszName, int iSize, void *p
|
|||
{
|
||||
ConsolePrint( rgDeathNoticeList[i].szVictim );
|
||||
|
||||
if ( !strcmp( killed_with.c_str(), "d_world" ) )
|
||||
if ( !strcmp( killed_with.c_str(), "world" ) )
|
||||
{
|
||||
ConsolePrint( " died" );
|
||||
}
|
||||
|
@ -297,7 +299,7 @@ int CHudDeathNotice :: MsgFunc_DeathMsg( const char *pszName, int iSize, void *p
|
|||
ConsolePrint( rgDeathNoticeList[i].szVictim );
|
||||
}
|
||||
|
||||
if ( !killed_with.empty() && killed_with != "d_world" && !rgDeathNoticeList[i].iTeamKill )
|
||||
if ( !killed_with.empty() && killed_with != "world" && !rgDeathNoticeList[i].iTeamKill )
|
||||
{
|
||||
ConsolePrint( " with " );
|
||||
|
||||
|
@ -306,7 +308,7 @@ int CHudDeathNotice :: MsgFunc_DeathMsg( const char *pszName, int iSize, void *p
|
|||
killed_with = "d_gluon gun";
|
||||
if ( killed_with == "gauss" )
|
||||
killed_with = "d_tau cannon";
|
||||
ConsolePrint( killed_with.c_str()+2 ); // skip over the "d_" part
|
||||
ConsolePrint( killed_with.c_str()); // skip over the "d_" part
|
||||
}
|
||||
|
||||
ConsolePrint( "\n" );
|
||||
|
|
Loading…
Reference in a new issue