/setadminname issue
#1

When i try to kick some 1 ban some 1or /setadmin /prison /jail no cmd working some 1told me its plugin issue can u tell me what i have to do he saw my cmd there is no issue isssue is my plaugin or etc

CMD IS HERE

PHP код:
CMD:setadminname(playeridparams[])
{
    if(
PlayerInfo[playerid][pAdmin] >= 5)
    {
        
/*if(AdminDuty[playerid] != 1 && PlayerInfo[playerid][pAdmin] < 6)
        {
            SendClientMessage(playerid,COLOR_WHITE, "You're not on-duty as admin. To access your admin commands you must be on-duty. Type /aduty to go on-duty.");
            return 1;
        }*/
        
new giveplayeridname[32];
        if(
sscanf(params"us[32]"giveplayeridname))
        {
            
SendClientMessage(playeridCOLOR_WHITE"USAGE: /setadminname [playerid/partofname] [name]");
            return 
1;
        }
        if(
PlayerInfo[giveplayerid][pAdmin] < 1)
        {
            
SendClientMessage(playeridCOLOR_WHITE"The player is not an admin.");
            return 
1;
        }
        if(
AdminDuty[giveplayerid] != 0)
        {
            
SendClientMessage(playeridCOLOR_WHITE"That admin is currently on-duty. They must go off-duty in order for you to set their admin name.");
            return 
1;
        }
        new 
length strlen(name);
        if(
length || length 20)
        {
            
SendClientMessage(playeridCOLOR_WHITE"The name can't less than 3 characters or more than 20 characters.");
            return 
1;
        }
        if(
strfind(name"_"true) != -1)
        {
            
SendClientMessage(playeridCOLOR_WHITE"The admin name must be one name. There can't be an underscore in the name.");
            return 
1;
        }
        if(
strcmp(name"Usama"true) == && PlayerInfo[playerid][pAdmin] < 6) {
            
SendClientMessage(playeridCOLOR_WHITE"stop ! im Usama ! you're not Usama !");
            return 
1;
        }
        new 
string[128];
        
format(stringsizeof(string), "AdmCmd: %s has set %s's admin name to '%s'."GetPlayerNameEx(playerid),  GetPlayerNameEx(giveplayerid), name);
        
ABroadCast(COLOR_LIGHTREDstring1);
        
format(PlayerInfo[giveplayerid][pAdminName], 32name);
    }
    else 
SendClientMessage(playeridCOLOR_GRAD1"You're not authorized to use that command!");
    return 
1;

Reply


Messages In This Thread
/setadminname issue - by Usama651 - 23.07.2016, 21:27
Re: /setadminname issue - by Stinged - 23.07.2016, 22:12
Re: /setadminname issue - by Usama651 - 24.07.2016, 03:42
Re: /setadminname issue - by GuyB790 - 24.07.2016, 03:53
Re: /setadminname issue - by Usama651 - 24.07.2016, 03:58
Re: /setadminname issue - by CrazyPerry - 24.07.2016, 05:46

Forum Jump:


Users browsing this thread: 1 Guest(s)