Untitled
By: a guest | Mar 21st, 2010 | Syntax:
PAWN | Size: 1.90 KB | Hits: 102 | Expires: Never
if (strcmp("/afk", cmdtext, true, 10) == 0)
{
if((afkbrb) == 0)
{
afkbrb1[playerid]=1;
//new string[48];
new string1[48];
GetPlayerName(playerid, playername, sizeof(playername));
format(string1, sizeof(string1), "%s is now AFK.", playername);
SendClientMessageToAll(COLOR_LIGHTBLUE, string1);
AFK[playerid] = Create3DTextLabel("AFK",0x008080FF,0.0,0.0,0.0,20,0,1);
Attach3DTextLabelToPlayer(AFK[playerid], playerid, 0.0, 0.0, -0.6);
TogglePlayerControllable(playerid,0);
afkbrb = 1;
return 1;
}else
SendClientMessage(playerid, 0x99ffccff,".AFK - àúä ëáø áîöá");
return 1;
}
//}
if (strcmp("/back", cmdtext, true, 10) == 0)
{
if((afkbrb) == 1)
{
// new string[48];
afkbrb1[playerid]=0;
format(string, sizeof(string), "%s is now Back.", playername);
SendClientMessageToAll(COLOR_LIGHTBLUE, string);
Delete3DTextLabel(Text3D:AFK[playerid]);
TogglePlayerControllable(playerid,1);
afkbrb = 0;
return 1;
}else
SendClientMessage(playerid, 0x99ffccff,".AFK - àúä ìà áîöá");
return 1;
}
// }
if(strcmp(cmdtext, "/afklist", true) == 0)
{
if(IsPlayerConnected(playerid))
{
new count = 0;
SendClientMessage(playerid, COLOR_LIGHTGREEN, "AFKS Online:");
for(new i=0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if((afkbrb) == 1)
{
GetPlayerName(i, giveplayer, sizeof(giveplayer));
format(string, sizeof(string), "[ID: %d] %s", i,giveplayer);
SendClientMessage(playerid,COLOR_WHITE,string);
count++;
}
}
}
if(count == 0)
{
SendClientMessage(playerid,COLOR_RED,"* àéï çáøé àô÷ îçåáøéí.");
}
}
return 1;
}