Jump to content
  • 0

Ajutor : Level 0 pe server


WalkerBlain

Question

Recommended Posts

  • 0

public OnPlayerConnect(playerid)
{
       if(IsPlayerNPC(playerid)) return 1;

        new ConnIP[16];
        GetPlayerIp(playerid,ConnIP,16);
        new compare_IP[16];
        new number_IP = 0;
        for(new i=0; i<MAX_PLAYERS; i++) {
                if(IsPlayerConnected(i)) {
                    GetPlayerIp(i,compare_IP,16);
                    if(!strcmp(compare_IP,ConnIP)) number_IP++;
                }
        }
        if((GetTickCount() - Join_Stamp) < Time_Limit)
            exceed=1;
        else
            exceed=0;
        if(strcmp(ban_s, ConnIP, false) == 0 && exceed == 1 )
        {
            Same_IP++;
            if(Same_IP > SAME_IP_CONNECT)
            {
                        Kick(playerid);
                        Same_IP=0;
            }
        }
        else
        {
                Same_IP=0;
        }
        if(number_IP > IP_LIMIT)
        Kick(playerid);
        GetStampIP(playerid);
        

    TempBanCheck(playerid);
    MsCP[playerid] = 0;
    HisPrecedentVehicle[playerid] = (-1);

Edited by WalkerBlain
Link to comment
Share on other sites

  • 0

arata in continuare, trebuie sa fie multe ceva gen TestPoints[playerid] = 0;

    OfficerCourseStep[playerid] = 255;
    IsPlayerInEVehicle[playerid] = 9999;
    Searching[playerid] = 0;
    admin[playerid] = 0;
    AFK[playerid] = 0;
    UsedAreaRecently[playerid] = 0;
    SelectChar[playerid] = 0;
    HidePM[playerid] = 0;
    PhoneOnline[playerid] = 0;
    SelectCharID[playerid] = 0;
    fireinfo[playerid] = 0;
    ghost[playerid] = 0;
    PlayerInfo[playerid][pplane] = 0

si pune spoiler pentru ele sau code pentru ca o s fie multe

Link to comment
Share on other sites

  • 0

Adauga la OnPlayerSpawn la inceput

SetPlayerScore(playerid, PlayerInfo[playerid][pLevel])

PlayerInfo[playerid][pLevel] - e posibil sa difere.

 

Te-am intrebat de text-ul la gamemode pentru ca m-am gandit ca e o eroare in gamemode si nu il citeste.

Link to comment
Share on other sites

  • 0

La asta te referi ? o comanda pt un jucator de level 2+

 

CMD:ad(playerid, params [])
{
   new string[128];
   if(PlayerInfo[playerid][pMuted] == 1) return SendClientMessage(playerid, COLOR_LIGHTRED, "You cannot speak, you have been silenced. Use {33CCFF}/mutetime");
   if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_GRAD1, "You havent logged in yet !");
   if(PlayerInfo[playerid][pLevel] < 2)
    {
        SendClientMessage(playerid, COLOR_GRAD1, "You must be level 2 to use Advertisment command.");
        return 1;
    }
   if(sscanf(params, "s[128]", params)) return SendClientMessage(playerid, COLOR_ORANGE, "{F97804}USAGE:{B4B5B7}{FFFFFF} (/ad)vertise [advert text]");
   if(strlen(params) > 50) return SendClientMessage(playerid, COLOR_GRAD1, "Maximum characters allowed per advertisement are 50.");
   if (adds == 0 && PlayerInfo[playerid][pAdmin] == 0) return SendClientMessage(playerid, COLOR_LIGHTBLUE, "[ANTI-SPAM]{B4B5B7} Please try againg later in 60 seconds");
   new payout = strlen(params) * 25;
   if(Justadvertise[playerid] == 1)
   {
       SendClientMessage(playerid, COLOR_LIGHTBLUE, "[ANTI-SPAM]{B4B5B7} Please try againg later in 60 seconds");
       return 1;
   }

Link to comment
Share on other sites

  • 0

public DollahScoreUpdate()
{
    new LevScore;
    for(new i=1; i<MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
               LevScore = PlayerInfo[pLevel] ;
            SetPlayerScore(i, LevScore);
            SetPlayerMoney(i, PlayerInfo[pCash]);
        }
    }
    return 1;
}

Link to comment
Share on other sites

  • 0

Nu inteleg ce vrei sa zici, vrei ca jucatorul ce intra pe server, sa primeasca score sau ce? Habar nu am la ce te referi, specifica-mi cu mai multe detali..

Deci , intru pe server si cand apas TAB , la score apare 0 .. iar masinile de pe server nu imi apar , doar cele personale .

Ai cumva server-ul pe MySQL?

 

Sau incarci datele despre cont bine?

Da server-ul este pe MySQL. Si da incarc datele bine..

Edited by WalkerBlain
Link to comment
Share on other sites

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.