[Help] Somethings wrong with my Admin commands?
#1

Hello SAMP members.

I've made this Admin filterscript, login etc works. but reading from the dudb file doesnt work?

heres one of the codes that doesnt work

pawn Код:
dcmd_ah(playerid, params[])
{
    #pragma unused params
    if(PlayerInfo[playerid][LoggedIn] == 0) return SendClientMessage(playerid, COLOR_RED, "[NiixieDM]: You need to be logged in to use that command!");

    if(PlayerInfo[playerid][AdminLevel] == 1)
    {
        SendClientMessage(playerid, COLOR_YELLOW, "");
        SendClientMessage(playerid, COLOR_YELLOW, "");
        SendClientMessage(playerid, COLOR_YELLOW, "******** NiixieDM - Admin Help ********");
        SendClientMessage(playerid, COLOR_YELLOW, "");
        SendClientMessage(playerid, COLOR_YELLOW, "/Kick - Kicks a player (Level: 1)");
        SendClientMessage(playerid, COLOR_YELLOW, "/Ban - Bans a player (Level: 2)");
        SendClientMessage(playerid, COLOR_YELLOW, "/Slap - Slaps a player (Level: 1)");
        SendClientMessage(playerid, COLOR_YELLOW, "/Sethealth - Sets a players health (Level: 1)");
        SendClientMessage(playerid, COLOR_YELLOW, "");
        SendClientMessage(playerid, COLOR_PINK, "/ah2 - Shows you more admin commands");
    }
    return SendClientMessage(playerid, COLOR_RED, "[NiixieDM]: You are not authorized to use that command!");
}
Im admin level 3 and still doesnt have permission?
Whats wrong?
Reply
#2

pawn Код:
//  if(dUserINT(PlayerName(playerid)).("Admin") <= 1)
Less < More

So pretty much, that statement says "If you are admin level 1 or less it will continue".

Reply
#3

If you look good at it with your sharp eyes you can see that its commented.. i were testing something with that '<''>' sign
Reply
#4

Anyone?
I'd like help
Reply
#5

if(PlayerInfo[playerid][AdminLevel] == 1)
change this to
if(PlayerInfo[playerid][AdminLevel] >= 1)
Reply
#6

Arh, i used that in another script. why didnt i think of that?
-Thanks

EDIT: Can you tell me how i save the register file in a folder theres inside scriptfiles?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)