Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <fun>
#define PLUGIN "ZombieAttack"
#define VERSION "0.0"
#define AUTHOR "Bent/Soccdoodcss"
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_event("ResetHUD", "choose_zom", "be")
register_event("DeathMsg", "death_mes", "a")
//g_var = register_cvar("zombie_on", "1", ADMIN_BAN)
}
public choose_zom(id)
{
new CsTeams:team = cs_get_user_team(id)
if (team == CS_TEAM_T)
{
set_user_health(id, 200);
}
return PLUGIN_HANDLED
}
public death_mes()
{
new killer = read_data(1)
new victim = read_data(2)
if(cs_get_user_team(killer) == CS_TEAM_T || cs_get_user_team(victim) != CS_TEAM_T)
{
new name[32]
get_user_name(killer, name, 31)
set_hudmessage(0, 255, 0, 0.0, 0.3, 0, 6.0, 12.0)
show_hudmessage(victim, "%s the zombie, has KILLED YOU!", name)
}
return PLUGIN_HANDLED
}
EDIT: Wtf? when i paste the code into AMXX Studio, it goes on 1 line. Can someone fix this?