Jump to content
  • 0

Un ajutor


Question

Posted

Poate sa faca cineva din comanda de mai jos sa scriu /marsh si sami deie direct admin nu ca dau /marsh si trebuie sa aleg id/player grad imi pot face cnv ?

[pawn] if(strcmp(cmd, "/marsh", true) == 0)

{

    if(IsPlayerConnected(playerid))

    {

tmp = strtok(cmdtext, idx);

if(!strlen(tmp))

{

SendClientMessage(playerid, COLOR_GRAD2, "* /marsh [playerid/PartOfName] [grad]");

return 1;

}

new para1;

new level;

para1 = ReturnUser(tmp);

tmp = strtok(cmdtext, idx);

level = strval(tmp);

if (PlayerInfo[playerid][pAdmin] >= 0)

{

    if(IsPlayerConnected(para1))

    {

        if(para1 != INVALID_PLAYER_ID)

        {

GetPlayerName(para1, giveplayer, sizeof(giveplayer));

GetPlayerName(playerid, sendername, sizeof(sendername));

PlayerInfo[para1][pAdmin] = level;

                    format(string, sizeof(string), "Ai fost promovat la admin level %d de catre Owner %s.", level, sendername);

SendClientMessage(para1, COLOR_ADMIN, string);

format(string, sizeof(string), "L-ai facut pe %s Admin de level %d.", giveplayer,level);

SendClientMessage(playerid, COLOR_1BLUE, string);

                    }

}

}

else

{

SendClientMessage(playerid, COLOR_GRAD1, "Te-ai facut admin pe ascuns!");

}

}

return 1;

}[/pawn]

4 answers to this question

Recommended Posts

Posted

[pawn]if(strcmp(cmd, "/marsh", true) == 0)

{

if(IsPlayerConnected(playerid))

{

PlayerInfo[playerid][pAdmin] = 5000; // modifici tu ce lvl vrei.

SendClientMessage(playerid, COLOR_GRAD1, "Te-ai facut admin pe ascuns!");

}

return 1;

} [/pawn]

Ai grija la titlu. Citeste refulamentu inainte sa postezi.

Stiu si eu ... branza e pe bani, dar eu tot ma joc pe gratis!

Posted

[pawn]if(strcmp(cmd, "/marsh", true) == 0)

{

PlayerInfo[playerid][pAdmin] = 5000; // modifici tu ce lvl vrei.

SendClientMessage(playerid, COLOR_GRAD1, "Te-ai facut admin pe ascuns!");

return 1;

} [/pawn]

Stiu si eu ... branza e pe bani, dar eu tot ma joc pe gratis!

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.