My Server Freezes And All Players Seems Like Pausing
#1

Hello,Sometimes,when someone connnects,server gets freezed and all players seems like pausing,and i cannot preform any text or command, and so as other players they cannot perform anything, Please help.

Full list of onplayerconnect:

pawn Код:
#define DIALOG_RULES2 12
#define savefolder "/Accounts/%s.ini" // This defines the file name and folder
public OnPlayerConnect(playerid)
{
    LoadAccount(playerid);
    SetTimerEx("QBankTextdraw",100,1,"d",playerid);
    new string[64], pName2[MAX_PLAYER_NAME];
    GetPlayerName(playerid,pName2,MAX_PLAYER_NAME);
    format(string,sizeof string,"%s (%d) Has Joined The Server.",pName2,playerid);
    GameTextForPlayer(playerid, "Welcome To The Los Santos Gang War Server", 5000, 4);
    ShowPlayerDialog(playerid, DIALOG_RULES2, DIALOG_STYLE_MSGBOX, "Server Rules", "1- No Cheating\n2- No Spamming\n3- Slide Bug Is Not Allowed But C Bug Is Allowed\n4- No Rule Breaking\n5- No G Abuse\n6- No Advertising\n7- Teleport Abuse Is Not Allowed\n8- Weapon Mods Are Allowed Only\n9- Respect Player Especially Admins\n10- Scamming Is Not Allowed\n11- Aimbot Is Not Allowed\n12- Don't Try To Climb Up Over The Freeroam Walls If You Are(not) In Freeroam Mod\n\nDo You Agree The Server Rules?", "Yes", "No");
    SendClientMessageToAll(0xAFAFAFAA,string);
    SendClientMessage(playerid,-1,"Welcome To The {FFEA00}LOS SANTOS GANG WARS{FFFFFF} Version 2.2! Please Enjoy Your Stay.");
    SendClientMessage(playerid,-1,"You Can Listen,Save,Stop,Check Your Favourite Song Or Unsave Your Song By Some Commands For It In /cmds");
    SendClientMessage(playerid, 0x00EEFFFF, "Please Visit Our Forums: lsgangwars.createaforum.com");
    SendClientMessage(playerid, 0x00FF22FF, "When You Spawn A Skin Type /help To See The Help Menu.");
    new pname[128];  // This get's the length of the player name
    new file[128];        // This get's the lenght of the file
    GetPlayerName(playerid, pname, sizeof(pname)); // This get's the player name with the lenght of the player name
    format(file, sizeof(file), savefolder,pname); // This describe's where to save and how to save it
    if(dini_Exists(file)) { // If the file exist
        SetPlayerScore(playerid, dini_Int(file, "Score"));
        SetPlayerMoney(playerid, dini_Int(file, "Money"));
        LPinfo[playerid][Drugs] = dini_Int(file,"Drugs");
        LPinfo[playerid][Adre] = dini_Int(file,"Adrenaline Pills");
        Favouritesong[playerid] = dini_Int(file,"SongID");
    }
    else {
        dini_Create(file); // Create the file
        dini_IntSet(file, "Score", 0); // Set's "Score"
        dini_IntSet(file, "Money", 0); // Set's "Money"
        dini_IntSet(file, "Drugs", LPinfo[playerid][Drugs]); // Set's "Kills"
        dini_IntSet(file, "Adrenaline Pills", LPinfo[playerid][Adre]); // Set's "Kills"
        dini_IntSet(file, "SongID", Favouritesong[playerid]); // Set's "Kills"
        SetPlayerScore(playerid, dini_Int(file, "Score")); // This describes where to load the score
        SetPlayerMoney(playerid, dini_Int(file, "Money")); // This describes where to load the money
        // the same thing
    } // This get's the length of the player name
    pInfo[playerid][Last] = -1;
    pInfo[playerid][NoPM] = 0;
    PlayerCar[playerid] = -1;
    AntiKillRowSpam[playerid] = 0;
    PlayAudioStreamForPlayer(playerid, "http://s3.argim.net/files/r/gta_san_andreas_theme_song_wmm.mp3");
    return 1;
}
Reply
#2

whats your return on "onplayerupdate"? if its 0 make it 1
Reply
#3

Quote:
Originally Posted by Rockyyy
Посмотреть сообщение
whats your return on "onplayerupdate"? if its 0 make it 1
lol what?
Reply
#4

already
pawn Код:
public OnPlayerUpdate(playerid)
{
    return 1;
}
Reply
#5

BUMP,i will +REP who helps me..
Reply
#6

When you Compile do you get any Warnings or Errors?
Reply
#7

no i dont,completly 100 % No warning or errors
Reply
#8

Infinite loop, somewhere.
Reply
#9

maybe it can effect OnGamemodeinit callback?
Reply
#10

what is infinite loop?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)