#include <amxmodx>
#include <csx>
#include <colorchat>
new gcvarForum, gcvarHost;
public plugin_init()
{
register_plugin("Pokaz","0.2","emblaze")
set_task(250.0, "showTimer",0,"",0,"b")
gcvarForum=register_cvar("amx_forum", "CS")
gcvarHost=register_cvar("amx_hoster", "CS")
return PLUGIN_CONTINUE
}
public showTimer(id){
new nazwa[32]
get_pcvar_string(gcvarHost,nazwa, 31)
ColorChat(id,GREEN, "**^x01 Witamy na: ^x03%s",nazwa);
new forum[32]
get_pcvar_string(gcvarForum,forum, 31)
ColorChat(id,GREEN, "**^x01 Forum serwera: ^x03%s",forum)
new nextmap[32]
get_cvar_string("amx_nextmap",nextmap,31)
ColorChat(id,GREEN, "**^x01 Nastepna mapa: ^x03%s", nextmap)
if (get_cvar_float("mp_timelimit"))
{
new a = get_timeleft()
if (get_cvar_num("amx_time_voice"))
{
}
ColorChat(id,GREEN, "**^x01 Czas do konca mapy: ^x03%d^x04:^x03%02d", (a / 60), (a % 60))
}
//Delay for order
set_task(0.1, "showRank", 1);
}
public showRank(id){
new izStats[8], izBody[8]
new iRankPos, iRankMax
new Players[32], playerCount;
get_players(Players, playerCount);
new id2;
for (new i=0; i<playerCount; i++){
id2 = Players[i];
iRankPos = get_user_stats(id2, izStats, izBody)
iRankMax = get_statsnum()
ColorChat(id2, GREEN, "**^x01 Twoj rank wynosi:^x04 %d^x01/^x04%d", iRankPos, iRankMax)
}
}
Chciałbym aby ta informacja pojawiała się graczowi po połączeniu z serwerem. Wbijam wybieram team i pojawia się tylko mi (nie całemu serwerowi tylko widoczne dla mnie na czacie).