08.04.2012, 16:37
pawn Код:
forward TimeAFK(playerid);
public TimeAFK(playerid)
{
TogglePlayerControllable(playerid, 0);
return 1;
}
if(strcmp("/afk", cmdtext, true) == 0)
{
SetTimerEx("TimeAFK", 1800000, false, "d", playerid);
TogglePlayerControllable(playerid, 1)
new Name[MAX_PLAYER_NAME];
new string[256]
GetPlayerName(playerid, Name, MAX_PLAYER_NAME];
format(string, sizeof(string), "%s Entered into auto-away mode", Name);
SendClientMessageToAll(0xFFFFFFFF, string);
return 1;
}