[Pomoc] AFK kicker

Započeo xXxPored, Januar 31, 2013, 14:18:30 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 2 gostiju pregledaju ovu temu.

Skiripta koju koristim: moja
Detaljan opis problema: Zelim da napravim AFK kicker znaci kad je igrac recimo afk 300 sekundi tj 5 minuta da ga kickuje :)
Dio skripte: /
Neke slike ili video radi...: /

big respect 4 Blaeks Vuzimir  Shoorty Scripter HamZa

na kraj skripte
forward IdleKick();
public IdleKick()
{
foreach(Player, i)
{
if(IsPlayerConnected(i))
{
GetPlayerPos(i, PlayerPos[i][0], PlayerPos[i][1], PlayerPos[i][2]);
if(PlayerPos[i][0] == PlayerPos[i][3] && PlayerPos[i][1] == PlayerPos[i][4] && PlayerPos[i][2] == PlayerPos[i][5])
{
new plname[64];
new string[128];
GetPlayerName(i, plname, sizeof(plname));
format(string, sizeof(string), "AdmCmd: %s je kikan zbog: AFK", plname);
SendClientMessageToAll(COLOR_LIGHTRED, string);
Kick(i);
}
PlayerPos[i][3] = PlayerPos[i][0];
PlayerPos[i][4] = PlayerPos[i][1];
PlayerPos[i][5] = PlayerPos[i][2];
}
}
}
}

// na vrh
new idletimer;

// pod gamemodeexitfunc

KillTimer(idletimer);

// i pod ongamemodeinit

idletimer = SetTimer("IdleKick", 300000, 1);