20.07.2009, 10:09
pawn Код:
if(!strcmp(cmd,"/cuff",true))
{
giveplayername=ReturnUser(tmp); // this line
cmd=strtok(cmdtext,idx);
if(gTeam[playerid] == TEAM_POLICE)
{
if(!strlen(cmd)) return SendClientMessage(playerid,GREY,"USAGE: /cuff [playerid]");
if(!IsPlayerConnected(id)) return SendClientMessage(playerid,RED,"ERROR: Invalid player id!");
TogglePlayerControllable(id,0);
GameTextForPlayer(id, "~y~ Cuffed!",2500,3);
new str[128];
GetPlayerName(playerid, str, sizeof(str));
GetPlayerName(giveplayerid, giveplayername, sizeof(giveplayername));
format(str, sizeof(str), " * %s takes out his cuffs and places it on %s hands. ", str, giveplayername);
ProxDetector(50.0, playerid, str,0x6699FFAA,0x6699FFAA,0x6699FFAA,0x6699FFAA,0x6699FFAA);
return 1;
}
else
{
SendClientMessage(playerid, RED, "ERROR: You're not a police officer!");
}
return true;
}
Thank you.
And yes, I have searched.