admin komanda

Započeo Reza, April 21, 2010, 11:26:52 PRE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Evo napravio sam ovu komande

if(strcmp(cmd, "/givelic", true) == 0)
{
    if(IsPlayerConnected(playerid))
    {
        if(IsAnInstructor(playerid))
        {
            if(PlayerInfo[playerid][pAdmin] < 1337)
            {
                SendClientMessage(playerid, COLOR_GREY, "   Only admin lvl 1337 or higher can give away a License !");
                return 1;
            }
            new x_nr[256];
x_nr = strtok(cmdtext, idx);
if(!strlen(x_nr)) {
    SendClientMessage(playerid, COLOR_WHITE, "USAGE: /givelic [name] [playerid/PartOfName]");
    SendClientMessage(playerid, COLOR_WHITE, "Available names: Driving, Flying, Sailing, Fishing, Weapon.");
return 1;
}
    if(strcmp(x_nr,"driving",true) == 0)
{
            tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
    SendClientMessage(playerid, COLOR_WHITE, "USAGE: /givelic driverslicense [playerid/PartOfName]");
    return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
    if(giveplayerid != INVALID_PLAYER_ID)
    {
        GetPlayerName(playerid, sendername, sizeof(sendername));
        GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
            format(string, sizeof(string), "* You've given a Drivers License to %s.",giveplayer);
        SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
        format(string, sizeof(string), "* Admin %s has given you a Drivers License.",sendername);
        SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
        PlayerInfo[giveplayerid][pCarLic] = 1;
        return 1;
        }
}
else
{
    SendClientMessage(playerid, COLOR_GREY, "   That player is Offline !");
    return 1;
}
}
else if(strcmp(x_nr,"flying",true) == 0)
{
            tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
    SendClientMessage(playerid, COLOR_WHITE, "USAGE: /givelic flyinglicense [playerid/PartOfName]");
    return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
    if(giveplayerid != INVALID_PLAYER_ID)
    {
        GetPlayerName(playerid, sendername, sizeof(sendername));
        GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
            format(string, sizeof(string), "* You've given a Flying License to %s.",giveplayer);
        SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
        format(string, sizeof(string), "* Admin %s has given you a Flying License.",sendername);
        SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
        PlayerInfo[giveplayerid][pFlyLic] = 1;
        return 1;
}
}
else
{
    SendClientMessage(playerid, COLOR_GREY, "   That player is Offline !");
    return 1;
}
}
else if(strcmp(x_nr,"sailing",true) == 0)
{
            tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
    SendClientMessage(playerid, COLOR_WHITE, "USAGE: /givelic sailinglicense [playerid/PartOfName]");
    return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
    if(giveplayerid != INVALID_PLAYER_ID)
    {
        GetPlayerName(playerid, sendername, sizeof(sendername));
        GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
            format(string, sizeof(string), "* You've given a Sailing License to %s.",giveplayer);
        SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
        format(string, sizeof(string), "* Admin %s has given you a Sailing License.",sendername);
        SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
        PlayerInfo[giveplayerid][pBoatLic] = 1;
        return 1;
}
}
else
{
    SendClientMessage(playerid, COLOR_GREY, "   That player is Offline !");
    return 1;
}
}
else if(strcmp(x_nr,"fishing",true) == 0)
{
            tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
    SendClientMessage(playerid, COLOR_WHITE, "USAGE: /givelic fishinglicense [playerid/PartOfName]");
    return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
    if(giveplayerid != INVALID_PLAYER_ID)
    {
        GetPlayerName(playerid, sendername, sizeof(sendername));
        GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
            format(string, sizeof(string), "* You've given a Fishing License to %s.",giveplayer);
        SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
        format(string, sizeof(string), "* Admin %s has given you a Fishing License.",sendername);
        SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
        PlayerInfo[giveplayerid][pFishLic] = 1;
        return 1;
}
}
else
{
    SendClientMessage(playerid, COLOR_GREY, "   That player is Offline !");
    return 1;
}
}
else if(strcmp(x_nr,"weapon",true) == 0)
{
            tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
    SendClientMessage(playerid, COLOR_WHITE, "USAGE: /givelic weaponlicense [playerid/PartOfName]");
    return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
    if(giveplayerid != INVALID_PLAYER_ID)
    {
        GetPlayerName(playerid, sendername, sizeof(sendername));
        GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
            format(string, sizeof(string), "* You've given a Weapon License to %s.",giveplayer);
        SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
        format(string, sizeof(string), "* Admin %s has given you a Weapon License.",sendername);
        SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
        PlayerInfo[giveplayerid][pGunLic] = 1;
        return 1;
}
}
else
{
    SendClientMessage(playerid, COLOR_GREY, "   That player is Offline !");
    return 1;
}
}
        }
        else
        {
            SendClientMessage(playerid, COLOR_GREY, "   You are not Admin lvl 1337 or higher !");
            return 1;
        }
    }
    return 1;
}



i stavio sam sebe za admin lvl 1338

i kad dodem na server i upisem /givelic
pise mi niste admin 1337


pls pomozite


Kliknite-->registrirajte se i zaradite 
http://www.neobux.com/?r=neoreza

reza ti si toliko glup da sebi nemozes dokazati jebote xD

kao prvo, vidim da ti neznas ni osnovne matematike sto je manje, sto vece, a sto jednako

a ako zelis da tu komandu koriste i admin 1338 i 1337 onda umjesto < 1337 stvati  >= 1337

>= 1337 -to ti znaci da koristit komandu mogu i 1337 admin level i svi leveli veci od 1337
Mnogi me znaju, a mnogi misle da znaju.

geforce baze su ti starije od mojsija

Tomek matematika mi ide dobro no kad san bija kopira nesto san se zajeba xD


Kliknite-->registrirajte se i zaradite 
http://www.neobux.com/?r=neoreza

Citat: ...:::---REZA---:::... poslato April 21, 2010, 11:55:16 PRE PODNE
geforce baze su ti starije od mojsija

Tomek matematika mi ide dobro no kad san bija kopira nesto san se zajeba xD
meni govoris za GeForce?

Citat
Tomek matematika mi ide dobro no kad san bija kopira nesto san se zajeba xD

hmm kopiro....

CitatEvo napravio sam ovu komande

hmm napravio....
Vikend je policija nas hvata,
vikend je ode cijela plata,
oko nas stvari ukradene,
sve smo dali na planove i sheme..
||||:=:=:=:=:=:=::=:=:=:=:=:=:=:THE IVEX:=:=:=:=:=:=:=:=:=::=:=:=:=:=:=::=:|||| 


PS: Ne saljite mi nikakve pm jer neodgovaram na njih! Ako trebate nes pitajte ove pr0 skriptere pa neka vam kazu!Hvala !

da slazem se sa tobom jer on izgleda nema pojma o skriptanju jednostavno misli da moze skriptati odjednom i misli da je pametan a ustvari je .........pip