Server closes after few minutes from start
#10

Quote:
Originally Posted by Dwane
Посмотреть сообщение
It will print information about where the crash was occured to the server_log
so here i got it XD:
[15:22:46] [debug] Server crashed while executing UFFtest.amx
[15:22:46] [debug] AMX backtrace:
[15:22:46] [debug] #0 native fwrite () [00405710] from samp-server.exe
[15:22:46] [debug] #1 00002568 in ?? () from UFFtest.amx
[15:22:46] [debug] #2 00002838 in ?? () from UFFtest.amx
[15:22:46] [debug] #3 00113858 in public checklevel () from UFFtest.amx
[15:22:46] [debug] System backtrace:
[15:22:47] [debug] #0 004923e0 in ?? () from C:\Users\Pasha\Desktop\Ultra Fun Freeplay\samp-server.exe
[15:22:47] [debug] #1 0040534e in ?? () from C:\Users\Pasha\Desktop\Ultra Fun Freeplay\samp-server.exe

It writes something about checklevel, so here is checklevel fuction(it is called by timer every 1 minute)
pawn Код:
OnGameModeInit()
{
SetTimer("checklevel",60000,1);
}
forward checklevel();
public checklevel()
{
    for(new i; i<MAX_PLAYERS; i++)
    {
    if(IsPlayerConnected(i) && !IsPlayerNPC(i))
    {
    GetPlayerName(i,pname,sizeof(pname));
    format(hourss, sizeof(hourss), "%s-hours", pname);
    format(minutess, sizeof(minutess), "%s-minutes", pname);
    if(!dini_Isset("PLEVELS.txt",hourss) || !dini_Isset("PLEVELS.txt",minutess))
    {
        dini_IntSet("PLEVELS.txt",hourss,0);
        dini_IntSet("PLEVELS.txt",minutess,1);
    }
    else
    {
        if(dini_Int("PLEVELS.txt",minutess)<59)
        {
        dini_IntSet("PLEVELS.txt",minutess,dini_Int("PLEVELS.txt",minutess)+1);
        }

        if(dini_Int("PLEVELS.txt",minutess)>=59)
        {
        dini_IntSet("PLEVELS.txt",hourss,dini_Int("PLEVELS.txt",hourss)+1);
        dini_IntSet("PLEVELS.txt",minutess,0);
        }

    }
    }
    }
    return 1;
}
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)