Set new admin problem
#1

Hi, I have this problem with my serve, I cant make myself an 1338 admin.When i modify my user file it says incorrect password when I login.The /rcon login method doesen`t work either, it says I don`t have acces tothat command.Please help me with that!
Reply
#2

When you are editing the user file, make sure you are logged off the server.
Reply
#3

I am logged off.I shutdown the server also because it is hosted on my computer.
Reply
#4

check for The rcon Pass :
and if you puted The Right Numbers Or Deleted Some Thing -.-
Reply
#5

the password is correct because it says "You are succesfull logged as an admin now" but I have no acces to the /makeadmin command.
Reply
#6

Quote:
Originally Posted by altair009
Посмотреть сообщение
the password is correct because it says "You are succesfull logged as an admin now" but I have no acces to the /makeadmin command.
Well, maybe Your "/makeadmin" command is differently made than Your other commands.
By saying differently, I mean, are You sure it's > if(IsPlayerAdmin(playerid)) < ?

Because if Your "/makeadmin" command contains any other kind of a admin addition, like (for an example) > if(AdminLevel1[playerid] == 1).
Then...Logging-in as a RCON administrator cannot help You. You must make Yourself a admin by some other way, for an example:

Quote:

COMMAND:admin(playerid, params[])
{

AdminLevel1[playerid] = 1;
SendClientMessage(playerid, 0x33AA33AA, "You just made Yourself a admin, now You're able to use /makeadmin command."); // 0x33AA33AA - Green colour

return 1;
}

That's just an example,
i don't know. Can You post Your "/makeadmin" commad here, because we cannot help You more without seeing the code (command), mate.
Reply
#7

You must show /makeadmin command here
Reply
#8

This is my /makeadmin command
Код:
if(strcmp(cmd, "/makeadmin", true) == 0)
	{
	    if(IsPlayerConnected(playerid))
	    {
	        if (PlayerInfo[playerid][pAdmin] >= 1338)
			{
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /makeadmin [playerid/PartOfName] [level(1-1339)]");
					return 1;
				}
				new para1;
				new level;
				para1 = ReturnUser(tmp);
				tmp = strtok(cmdtext, idx);
				level = strval(tmp);
			    if(IsPlayerConnected(para1))
			    {
			        if(para1 != INVALID_PLAYER_ID)
			        {
						GetPlayerName(para1, giveplayer, sizeof(giveplayer));
						GetPlayerName(playerid, sendername, sizeof(sendername));
						PlayerInfo[para1][pAdmin] = level;
						printf("AdminInfo: %s has promoted %s to a level %d admin", sendername, giveplayer, level);
						format(string, sizeof(string), "You have been promoted to a level %d admin by %s", level, sendername);
						SendClientMessage(para1, COLOR_LIGHTBLUE, string);
						format(string, sizeof(string), "You have promoted %s to a level %d admin.", giveplayer,level);
						SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
						format(string, sizeof(string), "AdmInfo: {33CCFF}%s {FFFF00}has promoted {33CCFF}%s {FFFF00}to a level {33CCFF}%d {FFFF00}admin", sendername, giveplayer, level);
						SendAdminMessage(COLOR_YELLOW, string);
					}
				}
			}
			else
			{
				SendClientMessage(playerid, COLOR_ORANGE, "DENIED: {FFFFFF}You are not authorized to use that command.");
			}
		}
		return 1;
	}
Reply
#9

Change it to:
pawn Код:
if(strcmp(cmd, "/makeadmin", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            if (IsPlayerAdmin(playerid))
            {
                tmp = strtok(cmdtext, idx);
                if(!strlen(tmp))
                {
                    SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /makeadmin [playerid/PartOfName] [level(1-1339)]");
                    return 1;
                }
                new para1;
                new level;
                para1 = ReturnUser(tmp);
                tmp = strtok(cmdtext, idx);
                level = strval(tmp);
                if(IsPlayerConnected(para1))
                {
                    if(para1 != INVALID_PLAYER_ID)
                    {
                        GetPlayerName(para1, giveplayer, sizeof(giveplayer));
                        GetPlayerName(playerid, sendername, sizeof(sendername));
                        PlayerInfo[para1][pAdmin] = level;
                        printf("AdminInfo: %s has promoted %s to a level %d admin", sendername, giveplayer, level);
                        format(string, sizeof(string), "You have been promoted to a level %d admin by %s", level, sendername);
                        SendClientMessage(para1, COLOR_LIGHTBLUE, string);
                        format(string, sizeof(string), "You have promoted %s to a level %d admin.", giveplayer,level);
                        SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                        format(string, sizeof(string), "AdmInfo: {33CCFF}%s {FFFF00}has promoted {33CCFF}%s {FFFF00}to a level {33CCFF}%d {FFFF00}admin", sendername, giveplayer, level);
                        SendAdminMessage(COLOR_YELLOW, string);
                    }
                }
            }
            else
            {
                SendClientMessage(playerid, COLOR_ORANGE, "DENIED: {FFFFFF}You are not authorized to use that command.");
            }
        }
        return 1;
    }
And rcon login and use /makeadmin
Reply
#10

but in this case wouldn`t any player make himself admin?
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)