WItam, napisałem sobie taki plugin na DD2, jednak HUD nie pokazuje się gdy patrzymy na gracza(takie coś jak na CoD)
#include <amxmodx>
#include <amxmisc>
#include <fakemeta_util>
#define PLUGIN	"HUD"
#define AUTHOR	"Sqwareck"
#define VERSION	"1.0"
new nick[33]
new licznik_zabic[33]
public plugin_init()
{
	register_plugin(PLUGIN, VERSION, AUTHOR)
	register_event("DeathMsg", "SmiercGraczaKill", "a");
}
public pokaz_hud(id)
{
	
	if(is_user_connected(id))
	{
		if(!is_user_alive(id))
			
	{
		
		new target = pev(id, pev_iuser2);
		
		
		
		if(!target)
			
			return PLUGIN_CONTINUE;
			new armor = get_user_armor(target)
			new hp = get_user_health(target)
			get_user_name(target, nick, 32)
			new speed = fm_get_speed(target)
			set_hudmessage(target, 255, 0, 0.5, 0.23, 0, 0.0, 0.45, 0.0, 0.0);
			show_hudmessage(target,  "[Only DD2]^n[Nick: %s]^n[Zdrowie: %i]^n[Armor: %i] ^n[Predkosc: %i]^n[Seria Zabojstw: %i]", nick, hp, armor, speed,  licznik_zabic[target]);
		}
		new armor = get_user_armor(id)
		new hp = get_user_health(id)
		get_user_name(id, nick, 32)
		new timeleft = get_timeleft()
		new speed = fm_get_speed(id)
		set_hudmessage(id, 255, 0, 0.02, 0.23, 0, 0.0, 0.3, 0.0, 0.0);
		show_hudmessage(id,  "[Only DD2]^n[Nick: %s]^n[Zdrowie: %i]^n[Armor: %i] ^n[Predkosc: %i]^n[Seria Zabojstw: %i]^n[Reset za: %d:%02d]", nick, hp, armor, speed,  licznik_zabic[id], timeleft / 60, timeleft % 60);
	}
	else 
		remove_task(0)
	
	return PLUGIN_HANDLED
}
public client_putinserver(id)
{
	set_task(0.1, "pokaz_hud", id,_,_,"b");
}
public SmiercGraczaKill(id)
{
	new zabojca = read_data(1)
	new ofiara = read_data(2)
	
	licznik_zabic[zabojca]++;
	
	if(!is_user_alive(id))
	{
		licznik_zabic[ofiara] = 0;
	}
}
A tak apropo, macie może jakieś pomysły co by tu dodać? Dziękuję za jakąkolwiek pomoc.


 
Dodatki SourceMod





				
				






