Quote:
Originally Posted by Skorch
pawn Код:
COMMAND:kick(playerid, params[]) { if(isnull(params)) { SendClientMessage(playerid, 0x8094ABFF, "USAGE: /kick <player Id>"); } else { if(IsPlayerConnected(strval(params))) // checking if the player is connected { if(Group_GetPlayer(/*group 'Id' here*/, strval(params)) == Group_GetPlayer(/*group 'Id' here*/, playerid)) // check if the player groups matches { Group_SetPlayer(/*group 'Id' here*/, strval(params), false); // remove the player from group } } } return true; } COMMAND:invite(playerid, params[]) { if(isnull(params)) { SendClientMessage(playerid, 0x8094ABFF, "USAGE: /invite <player Id>"); } else { if(IsPlayerConnected(strval(params))) // checking if the player is connected { Group_SetPlayer(/*group 'Id' here*/, strval(params), true); // invite the player to the group! } } return true; }
You need to edit the CMD by yourself, but i gave you the base.
Don't know if there's any errors, didn't compile it.
|
Yea but still It has to save that THAT player is a member of that group, wouldnt Enums be needed?