04.10.2013, 22:23
Here's a way you could do it, just modify it to your needs:
pawn Код:
new InJail[MAX_PLAYERS];
CMD:sendtoooc(playerid, params[])
{
new targetid;
if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, -1, "Usage: /sendtoooc (name/id)");
if (!IsPlayerConnected(targetid)) return SendClientMessage(playerid, -1, "player is not connected.");
if(InJail[targetid] == 1)
{
SetPlayerPos(targetid, OOCPrisonSpawns[rand][0], OOCPrisonSpawns[rand][1], OOCPrisonSpawns[rand][2]);
}
else
{
SendClientMessage(playerid, -1, "Player is not in jail.");
}
return 1;
}