#include <amxmodx>
#define PLUGIN "Show Damage"
#define AUTHOR "AciD"
#define VERSION "1.0"
new m_victim, m_attacker
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_event("Damage", "show_damage", "b", "2!0", "3=0", "4!0")
m_victim = CreateHudSyncObj()
m_attacker = CreateHudSyncObj()
}
public show_damage(id)
{
new attacker = get_user_attacker(id)
if (is_user_connected(id) && is_user_connected(attacker))
{
new damage = read_data(2)
set_hudmessage(255, 0, 0, 0.45, 0.50, 2, 0.1, 4.0, 0.1, 0.1, -1)
ShowSyncHudMsg(id, m_attacker, "%i^n", damage)
set_hudmessage(0, 100, 200, -1.0, 0.55, 2, 0.1, 4.0, 0.02, 0.02, -1)
ShowSyncHudMsg(attacker, m_victim, "%i^n", damage)
}
}