10.07.2011, 21:50
Well your just going to have to make a command to give him access.
Then, just change the earlier OnPlayerRequestSpawn to:
And give him access:
Now you just save that the player is allowed in his user files so that you don't have to always redo it after he logs out.
pawn Код:
new AllowedPlayer[MAX_PLAYERIS];
pawn Код:
public OnPlayerRequestSpawn(playerid)
{
if(RestrictedSkin[playerid] == 1 && AllowedPlayer[playerid] ==0)
{
SendClientMessage(playerid, 0xFF0000FF, "Restricted Skin!");
return 0;
}
return 1;
}
pawn Код:
new subjectid;
if(strcmp(string, "/giveaccess", true) == 0)
{
string = strtok(cmdtext,idx);
if(!strlen(string))
{
SendClientMessage(playerid, COLOR_GREY, "USAGE: /giveaccess [playerid/partofname]");
return 1;
}
subjectid = ReturnUser(string);
SendClientMessage(playerid, 0xFFFFFFFF, "You have given access to the player");
SendClientMessage(subjectid, 0xFFFFFFFF, "You have recieved VIP access");
AllowedPlayer[subjectid] = 1;
}