2010-11-20 10:37:14 +00:00
|
|
|
/* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */
|
|
|
|
/* If you are missing that file, acquire a complete release at teeworlds.com. */
|
2010-05-29 07:25:38 +00:00
|
|
|
#ifndef GAME_CLIENT_COMPONENTS_KILLMESSAGES_H
|
|
|
|
#define GAME_CLIENT_COMPONENTS_KILLMESSAGES_H
|
|
|
|
#include <game/client/component.h>
|
|
|
|
|
|
|
|
class CKillMessages : public CComponent
|
|
|
|
{
|
2018-03-13 20:55:47 +00:00
|
|
|
int m_SpriteQuadContainerIndex;
|
2010-05-29 07:25:38 +00:00
|
|
|
public:
|
|
|
|
// kill messages
|
|
|
|
struct CKillMsg
|
|
|
|
{
|
2018-03-13 20:55:47 +00:00
|
|
|
CKillMsg()
|
|
|
|
{
|
|
|
|
m_KillerTextContainerIndex = m_VictimTextContainerIndex = -1;
|
|
|
|
}
|
|
|
|
|
2010-05-29 07:25:38 +00:00
|
|
|
int m_Weapon;
|
2018-03-13 20:55:47 +00:00
|
|
|
|
2010-06-06 13:38:03 +00:00
|
|
|
int m_VictimID;
|
|
|
|
int m_VictimTeam;
|
2015-04-12 13:19:47 +00:00
|
|
|
int m_VictimDDTeam;
|
2010-06-06 13:38:03 +00:00
|
|
|
char m_aVictimName[64];
|
2018-03-13 20:55:47 +00:00
|
|
|
int m_VictimTextContainerIndex;
|
|
|
|
float m_VitctimTextWidth;
|
2010-06-06 13:38:03 +00:00
|
|
|
CTeeRenderInfo m_VictimRenderInfo;
|
2018-03-13 20:55:47 +00:00
|
|
|
|
2010-06-06 13:38:03 +00:00
|
|
|
int m_KillerID;
|
|
|
|
int m_KillerTeam;
|
|
|
|
char m_aKillerName[64];
|
2018-03-13 20:55:47 +00:00
|
|
|
int m_KillerTextContainerIndex;
|
|
|
|
float m_KillerTextWidth;
|
2010-06-06 13:38:03 +00:00
|
|
|
CTeeRenderInfo m_KillerRenderInfo;
|
2018-03-13 20:55:47 +00:00
|
|
|
|
2010-05-29 07:25:38 +00:00
|
|
|
int m_ModeSpecial; // for CTF, if the guy is carrying a flag for example
|
|
|
|
int m_Tick;
|
|
|
|
};
|
2011-04-13 18:37:12 +00:00
|
|
|
|
2010-05-29 07:25:38 +00:00
|
|
|
enum
|
|
|
|
{
|
|
|
|
MAX_KILLMSGS = 5,
|
|
|
|
};
|
|
|
|
|
|
|
|
CKillMsg m_aKillmsgs[MAX_KILLMSGS];
|
|
|
|
int m_KillmsgCurrent;
|
|
|
|
|
|
|
|
virtual void OnReset();
|
|
|
|
virtual void OnRender();
|
|
|
|
virtual void OnMessage(int MsgType, void *pRawMsg);
|
2018-03-13 20:55:47 +00:00
|
|
|
virtual void OnInit();
|
2010-05-29 07:25:38 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|