Server keeps restarting, doesn't show online
#1

Hey guys,

My samp-server.exe runs fine and there are no errors in the script, but the server shows offline. Retrieving info, players 0/0 and ping "-". When I join the server it connects, then says "Jordan Baker has left the server (leaving), then says "server is restarting". This loop just continues. I installed crashdetect and this is what it shows. Any help on fixing this would be greatly appreciated!

Код:
----------
Loaded log file: "server_log.txt".
----------

SA-MP Dedicated Server
----------------------
v0.3.7-R2, ©2005-2015 SA-MP Team

[21:22:12] filterscripts = ""  (string)
[21:22:12] 
[21:22:12] Server Plugins
[21:22:12] --------------
[21:22:12]  Loading plugin: crashdetect.dll
[21:22:12]   CrashDetect v4.18.1 is OK.
[21:22:12]   Loaded.
[21:22:12]  Loading plugin: streamer.dll
[21:22:12] 

*** Streamer Plugin v2.9.3 by Incognito loaded ***

[21:22:12]   Loaded.
[21:22:12]  Loaded 2 plugins.

[21:22:12] 
[21:22:12] Filterscripts
[21:22:12] ---------------
[21:22:12]   Loaded 0 filterscripts.

[21:22:12] Stage 1
[21:22:12] Dynamic Radio System: Created a radio station: "ID 1", Name: 'Country Music'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 2", Name: 'Modern Hiphop'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 3", Name: 'Kiss FM'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 4", Name: 'DeJay R&B'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 5", Name: 'Hot 108 JamZ'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 6", Name: 'CroniX Agresstion'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 7", Name: 'Sky FM - Top Hitz'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 8", Name: 'HouseTime FM - Electro'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 9", Name: 'Smooth Jazz FM'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 10", Name: 'SlowRaDio FM'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 11", Name: 'Gay FM - Pure Dance'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 12", Name: 'TDI Radio - Dance'
[21:22:12] Dynamic Radio System: Created a radio station: "ID 13", Name: '181.FM - The Buzz'
[21:22:12] Stage 2
[21:22:13] Stage 3
[21:22:13] Stage 4
[21:22:13] Stage 5
[21:22:13] Stage 6
[21:22:13] Stage 7
[21:22:13] Stage 8
[21:22:13] Stage 8
[21:22:13] Stage 9
[21:22:13] Stage 10
[21:22:13] Stage 11
[21:22:13] [debug] Run time error 4: "Array index out of bounds"
[21:22:13] [debug]  Attempted to read/write array element at index 72 in array of size 72
[21:22:13] [debug] AMX backtrace:
[21:22:13] [debug] #0 00379878 in public AddCar (72) from AZRP.amx
[21:22:13] [debug] #1 00343d24 in public Iter_OnGameModeInit () from AZRP.amx
[21:22:13] [debug] #2 native CallLocalFunction () from samp-server.exe
[21:22:13] [debug] #3 00002bb0 in public OnGameModeInit () from AZRP.amx
[21:22:13]  
[21:22:13]  
[21:22:13] AZ-RP v2.4
[21:22:13] ______________
[21:22:13]  
[21:22:13] Number of vehicle models: 81
Reply
#2

Show that "AddCar"
Reply
#3

The only AddCar I have in my script
Код:
forward AddCar(carcoords);
public AddCar(carcoords)
and
Код:
//cut from script
print("Stage 11");
	for(new i = 0; i < 165; i++)
	{
		AddCar(i);
	}
	print("Stage End");
	return 1;
}
Reply
#4

Whatever array you are using for your cars, only has 72 vehicles in it, yet it's looking for 165. Check the array of the cars for any faults in it.
Reply
#5

Maybe you're using GameModeExit(); somewhere in there?
Reply
#6

@sew_sumi, sorry I haven't been scripting for a while so I've forgotten a lot of things, but how can I fix that problem?

@RogueDrifter, thanks heaps for your reply! I don't think that's the problem, although let me know if you see anything wrong with this
Код:
public LoadStuff()
{
	new arrCoords[16][64];
	new strFromFile2[256];
	new File: file = fopen("stuff.ini", io_read);
	if(file)
	{
		fread(file, strFromFile2);
		split(strFromFile2, arrCoords, ',');
		Jackpot = strvalEx(arrCoords[0]);
		Tax = strvalEx(arrCoords[1]);
		TaxValue = strvalEx(arrCoords[2]);
		Security = strvalEx(arrCoords[3]);
		Kicks = strvalEx(arrCoords[5]);
		Fines = strvalEx(arrCoords[6]);
		Prisons = strvalEx(arrCoords[7]);
		Slaps = strvalEx(arrCoords[8]);
		Bans = strvalEx(arrCoords[9]);
		Jails = strvalEx(arrCoords[10]);
		Spins = strvalEx(arrCoords[11]);
		MaxPlayers = strvalEx(arrCoords[12]);
		Reports = strvalEx(arrCoords[13]);
		factionsrecentlypaid = strvalEx(arrCoords[14]);
		factionpaytimer = strvalEx(arrCoords[15]);
		fclose(file);
		if(Security == 0 || Security == 1)
		{
		}
		else
		{
		    GameModeExit();
		}
	}
	else
	{
	    GameModeExit();
	}
	return 1;
}
Reply
#7

Does 'stuff.ini' exist? If yes, does it have proper settings?
Reply
#8

Just realized I don't have any of my scriptfiles! I re-downloaded the script I created from DropBox about a year ago and I didn't save any of the scriptfiles. How can I know what scriptfile folders I have to add?

EDIT: Scratch that, I just found the scriptfiles. I'll recompile the script and let you know how it goes
Reply
#9

fixed!
Reply
#10

Quote:
Originally Posted by Josh_Main
Посмотреть сообщение
@sew_sumi, sorry I haven't been scripting for a while so I've forgotten a lot of things, but how can I fix that problem?

@RogueDrifter, thanks heaps for your reply! I don't think that's the problem, although let me know if you see anything wrong with this
Код:
public LoadStuff()
{
	new arrCoords[16][64];
	new strFromFile2[256];
	new File: file = fopen("stuff.ini", io_read);
	if(file)
	{
		fread(file, strFromFile2);
		split(strFromFile2, arrCoords, ',');
		Jackpot = strvalEx(arrCoords[0]);
		Tax = strvalEx(arrCoords[1]);
		TaxValue = strvalEx(arrCoords[2]);
		Security = strvalEx(arrCoords[3]);
		Kicks = strvalEx(arrCoords[5]);
		Fines = strvalEx(arrCoords[6]);
		Prisons = strvalEx(arrCoords[7]);
		Slaps = strvalEx(arrCoords[8]);
		Bans = strvalEx(arrCoords[9]);
		Jails = strvalEx(arrCoords[10]);
		Spins = strvalEx(arrCoords[11]);
		MaxPlayers = strvalEx(arrCoords[12]);
		Reports = strvalEx(arrCoords[13]);
		factionsrecentlypaid = strvalEx(arrCoords[14]);
		factionpaytimer = strvalEx(arrCoords[15]);
		fclose(file);
		if(Security == 0 || Security == 1)
		{
		}
		else
		{
		    GameModeExit();
		}
	}
	else
	{
	    GameModeExit();
	}
	return 1;
}
I was right you were using gamemodeexit lol anyhow glad its fixed.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)