Could this be the cause?
#1

Hi,

I recently upgraded my servers slots to 75.
And I forgot to change the:

pawn Код:
#define MAX_PLAYERS 50 //max slots
my server has been experiencing lots of timeouts. Could this be the cause? Because I haven't updated the define to 75 ?

Theres also a few leaves but that probably doesn't matter.

Thanks

EDIT: A whole load of players just left. This must be the cause.
Hes my irc:
pawn Код:
<@ES1> >> [37] Kurok has spawned.
<%ES2> >> [37] Kurok has left the server. (Leaving)
<%ES3> >> [2] acceleration has left the server. (Timeout)
<%ES4> >> [2] Killer_Junior has joined the server.
<%ES5> >> [38] 5555 has left the server. (Leaving)
<%ES6> >> [36] Bezimienny has left the server. (Leaving)
<@ES1> [7] alvin: .usr`
<%ES2> [GMS]Viktor has spawned a Bullet (Model:41)
<%ES3> >> [32] g1g0 has left the server. (Leaving)
<%ES4> >> [2] Killer_Junior has spawned.
<%ES5> >> [11] ByCarizma has left the server. (Leaving)
<%ES6> >> [26] JusT has left the server. (Timeout)
<@ES1> >> balkanstunt died. (Collision)
<%ES2> >> [14] GRISHA has spawned.
<%ES3> >> [10] balkanstunt has left the server. (Leaving)
Reply
#2

I'm not sure, but better change it to improve performance.
Reply
#3

Quote:
Originally Posted by RyDeR`
Посмотреть сообщение
I'm not sure, but better change it to improve performance.
I edited it read up.
Reply
#4

It might the host getting blocked or something.
Reply
#5

Quote:
Originally Posted by Gazmull
Посмотреть сообщение
It might the host getting blocked or something.
What do you mean ? We got a new host ,we're sure it's not that.
Also this is what I think.

for(new i = 1; i < 50; i++) Thats a loop , what i think im doing is undefining 75 slots. Then defining 50. And im only looping through 50 players and not 75. So the timeouts are caused by the loops failing and some other timeer complicated stuff and everytime the server fills up to like 30. The players are being pushed out as only 50 slots are defined. but really there are 75.

I do have more loops , anyway thats what I think. Though it probably doesn't make much sense. I'm tired lol.
Reply
#6

On my own script i use:
pawn Код:
for(new i = 0; i < MAX_PLAYERS; i ++)
Reply
#7

Quote:
Originally Posted by Gazmull
Посмотреть сообщение
On my own script i use:
pawn Код:
for(new i = 0; i < MAX_PLAYERS; i ++)
But I have my own defines...
pawn Код:
#undef MAX_PLAYERS
#define MAX_PLAYERS 50
But I upgraded my slots to 75 and forgot to change them , they're also used for loops. As you can see.
Reply
#8

For future references, you should use foreach. It's way more efficient. Also saves you alot of code, as all you have to do is foreach (Player, i), and you have a loop.

If you've already changed the define to 75, I really don't think that's the cause. See if you can find out where the crash happens. (roughly) And start debugging your script. Eventually you'll find where exactly the server crashes.
Reply
#9

Quote:
Originally Posted by shitbird
Посмотреть сообщение
For future references, you should use foreach. It's way more efficient. Also saves you alot of code, as all you have to do is foreach (Player, i), and you have a loop.

If you've already changed the define to 75, I really don't think that's the cause. See if you can find out where the crash happens. (roughly) And start debugging your script. Eventually you'll find where exactly the server crashes.
No , my friend is out who has access to the hoster. I have changed the slots define to 75. But haven't uploaded it yet , I need to wait for my friend before I can, so could it be this ? There are still lots of timeouts/leaves now. Also I wasn't planning on updating to foreach , I think this is the problem.

another mass leave:

pawn Код:
<%ES3> >> [34] vladik_shumilov has left the server. (Leaving)
<%ES4> >> [11] kingnight14 has spawned.
<%ES5> >> [6] [driftxa]WhiteBlack has left the server. (Leaving)
<%ES6> >> [22] Timur_Garaev has left the server. (Leaving)
<@ES1> >> [27] stenli has left the server. (Leaving)
<%ES2> >> [6] vadim has joined the server.
Reply
#10

If you're changing your slots too regularly you better use "GetMaxPlayers()" or more simple and fast foreach.

I'm not sure why you have so many timeouts; the reason could be everything. Try to change MAX_PLAYERS to the amount of your server slots and see if it helps.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)