11.12.2009, 06:17
hey there i need some help i have this script
but i whant to be able to make this line..
range from 1 - 5 so if someone could help that would be great
So i Can Go /giveadmin [playerid] [1-5]
Код:
if (strcmp(cmd, "/giveadmin", true) ==0 )
{
if(PlayerInfo[playerid][Admin] >= 5)
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD1, "USAGE: /giveadmin[playerid] ");
return 1;
}
giveplayerid = ReturnUser(tmp);
if (IsPlayerConnected(giveplayerid))
{
PlayerInfo[giveplayerid][Admin] = 1;
SendClientMessage(giveplayerid, COLOR_GRAD1, "You Have been Given Admin");
}
else
{
SendClientMessage(giveplayerid, COLOR_GRAD1, "Player Is Not On The Sever");
}
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, "You Are Not Admin");
}
return 1;
}
but i whant to be able to make this line..
Код:
PlayerInfo[giveplayerid][Admin] = 1;
So i Can Go /giveadmin [playerid] [1-5]

