#include a_samp
new pName[MAX_PLAYER_NAME],stringname[200], name[MAX_PLAYER_NAME];
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp(\"/afk-be\", cmdtext, true) == 0)
{
SendClientMessage(playerid,0x99FF00AA,\"Ha visszajöttél öcsém /afk-ki\");
TogglePlayerControllable(playerid, 0);
GetPlayerName(playerid, name, sizeof name);
GetPlayerName(playerid, pName, sizeof pName);
format(stringname, sizeof stringname, \"[AFK]%s\", pName);
SetPlayerName(playerid, stringname);
return 1;
}
if (strcmp(\"/afk-ki\", cmdtext, true) == 0)
{
TogglePlayerControllable(playerid, 1);
SetPlayerName(playerid, name);
return 1;
}
return 0;
}
Ennyi lenne