08.01.2011, 00:37
you will need sscan f and zcmd
Код:
CMD:kick(playerid, params[]) { new id, reson[128], string[ 128 ]; if( sscanf( params, "uz", reson) ) { if(PlayerInfo[playerid][pAdminLevel] >= 1)// put your admin level thing here { SendClientMessage(playerid, WHITE, "[SEVER]:{20DB16} Usage /kick [ID] [RESON]"); } } else { if(PlayerInfo[playerid][pAdminLevel] >= 1) { if(IsPlayerConnectedEx(id) ) { if(PlayerInfo[playerid][pAdminLevel] >= PlayerInfo[id][pAdminLevel]) { format(string, sizeof(string), "You have bean KICK By a Admin %s Because of %s", GetNameEx(playerid), params); NearByMessage(playerid, WHITE, string); Kick( id ); } } else { SendClientMessage( playerid, WHITE, "That player is not connected or isn't logged in." ); } } } return 1; }