Jump to content

Iulian

Membru
  • Posts

    191
  • Joined

  • Last visited

Posts posted by Iulian

  1. Salut, am si eu un server de samp si tot intra cineva si se face admin :(( Am bagat asta

    [pawn]public OnRconLoginAttempt(ip[], password[], success)

    {

        if(success) return 1;

        new pip[16], pName[24];

        for(new i=0; i<MAX_PLAYERS; i++)

        {

            GetPlayerIp(i, pip, sizeof(pip));

            if(!strcmp(ip, pip, true))

            {

                GetPlayerName(i, pName, 24);

                if(strcmp(pName, "Brain_OConner"))

                {

                    SendClientMessage(i, COLOR_LIDER, "Nu esti Brain!");

                    PlayerInfo[pLocked] = 1

                    Ban(i);

                }

            }

        }

        return 1;

    }[/pawn]

    si tot ma baneaza :(( va rog ma ajutati ?

  2. Buna vreau sa fac o comanda /pchat (pentru intrare si iesire din chatul premium si sa o adaug in gm)

    Cand scrie cineva /pchat sa anunte membrii de pe chatul premium (doar cei care sunt conectati) ca a intrat/iesit un player

    [pawn] if(strcmp(cmd, "/premium", true) == 0 || strcmp(cmd, "/p", true) == 0)

    {

        if(IsPlayerConnected(playerid))

        {

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

    new length = strlen(cmdtext);

    while ((idx < length) && (cmdtext[idx] <= ' '))

    {

    idx++;

    }

    new offset = idx;

    new result[64];

    while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))

    {

    result[idx - offset] = cmdtext[idx];

    idx++;

    }

    result[idx - offset] = EOS;

    if(!strlen(result))

    {

    SendClientMessage(playerid, COLOR_GRAD2, "USAGE: (/p)remium [premium chat]");

    return 1;

    }

    format(string, sizeof(string), "{FF00FF}Admin{FFFFFF} %s: %s", sendername, result);

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

    {

    SendPremiumMessage(0x999900FF, string);

    }

    else if(PlayerInfo[playerid][pDonateRank] >= 1)

                {

                    format(string, sizeof(string),"{FFCC00}Premium {FFFFFF}%s: %s", sendername, result);

                    SendPremiumMessage(0x999900FF, string);

                }

    printf("Admin %s: %s", sendername, result);

    }

    return 1;

    }[/pawn]

  3. Buna vreau sa fac o comanda /pchat (pentru intrare si iesire din chatul premium si sa o adaug in gm)

    Cand scrie cineva /pchat sa anunte membrii de pe chatul premium (doar cei care sunt conectati) ca a intrat/iesit un player

    [pawn] if(strcmp(cmd, "/premium", true) == 0 || strcmp(cmd, "/p", true) == 0)

    {

        if(IsPlayerConnected(playerid))

        {

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

    new length = strlen(cmdtext);

    while ((idx < length) && (cmdtext[idx] <= ' '))

    {

    idx++;

    }

    new offset = idx;

    new result[64];

    while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))

    {

    result[idx - offset] = cmdtext[idx];

    idx++;

    }

    result[idx - offset] = EOS;

    if(!strlen(result))

    {

    SendClientMessage(playerid, COLOR_GRAD2, "USAGE: (/p)remium [premium chat]");

    return 1;

    }

    format(string, sizeof(string), "{FF00FF}Admin{FFFFFF} %s: %s", sendername, result);

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

    {

    SendPremiumMessage(0x999900FF, string);

    }

    else if(PlayerInfo[playerid][pDonateRank] >= 1)

                {

                    format(string, sizeof(string),"{FFCC00}Premium {FFFFFF}%s: %s", sendername, result);

                    SendPremiumMessage(0x999900FF, string);

                }

    printf("Admin %s: %s", sendername, result);

    }

    return 1;

    }[/pawn]

×
×
  • 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.