Prosze o edycje pluginu
MaTusz
06.02.2010
Mógłbym prosić o dodanie aby po wyjsciu z serwera radar z powrotem byl ? Bo trzeba w konsoli wpisywac za kazdym razem
#include #include #define PLUG "GunGame Hud Rank Stats" #define VERS "4.0" #define AUTH "eXacT" new gMsgHudSync new cvar_hudcolor_red new cvar_hudcolor_green new cvar_hudcolor_blue const Float:HUD_STATS_X = 0.00 // Hud Mode Possition X (default 0.00) const Float:HUD_STATS_Y = 0.0 // Hud Mode Possition Y (default 0.0) public plugin_init() { register_plugin(PLUG, VERS, AUTH) gMsgHudSync = CreateHudSyncObj() cvar_hudcolor_red = register_cvar("gg_hud_color_red", "50") cvar_hudcolor_green = register_cvar("gg_hud_color_green", "135") cvar_hudcolor_blue = register_cvar("gg_hud_color_blue", "180") } public client_connect(id) { client_cmd(id, "hideradar") } public client_putinserver(id) { set_task(5.0,"ShowRank",id) } public client_disconnect(id) { if(task_exists(id)) remove_task(id) } public ShowRank(id) { static red, green, blue static stats[8], body[8] new Ranking = get_user_stats(id, stats, body) new name[33] get_user_name(id, name, 32) red = get_pcvar_num(cvar_hudcolor_red) green = get_pcvar_num(cvar_hudcolor_green) blue = get_pcvar_num(cvar_hudcolor_blue) set_hudmessage(red, green, blue, HUD_STATS_Y, HUD_STATS_X, 1, 1.0, 255.0, 0.0, 0.0, 3) ShowSyncHudMsg(id, gMsgHudSync, "Name: %s^nRank: %d^nKills: %d^nDeaths: %d^nHeadShots: %d", name, ranking, stats[0], stats[1], stats[2]) set_task(1.0, "ShowRank", id) }
Bad
07.02.2010
spróbuj dodac w client_disconnect
client_cmd(id, "showradar")moze bedzie dzialac
DarkGL
07.02.2010
jak już to powinno być
Użytkownik DarkGL edytował ten post 07.02.2010 12:02
client_cmd(id, "drawradar")
Użytkownik DarkGL edytował ten post 07.02.2010 12:02
MaTusz
07.02.2010
tzn gdzie dokladnie to dodac ?
jak mam
to wystarczy o w ten sposob ?
czy musze nowy pod tym dac
Użytkownik MaTusz edytował ten post 07.02.2010 17:28
jak mam
public client_disconnect(id) { if(task_exists(id)) remove_task(id) }
to wystarczy o w ten sposob ?
public client_disconnect(id) { client_cmd(id, "drawradar") if(task_exists(id)) remove_task(id) }
czy musze nowy pod tym dac
public client_disconnect(id) { client_cmd(id, "drawradar") }
Użytkownik MaTusz edytował ten post 07.02.2010 17:28
DarkGL
07.02.2010
wystarczy
public client_disconnect(id) { client_cmd(id, "drawradar") if(task_exists(id)) remove_task(id) }