Posts: 3
Threads: 1
Joined: Jun 2012
Reputation:
0
I have a problem. My server is lagged. It looks like a big lag (typically lasting 10-15 seconds, 5 second pause and then another), then all players turn coming out of the cause: crash. All logs are clean. This is not the fault host. It certainly is merit someone. What could be the reason? How to stop an attacker.
Server version: 0.3e
I apologize for my terrible English.
Posts: 3,351
Threads: 780
Joined: Jan 2010
Do you use OnPlayerUpdate?Also,don't use multiple timers.Try to categorize them in just one.
Also,reduce cells strings size.
If you've to parse a player name,[24] is enough.
If you've to create a string to send a ban message,[128] is enough.
Hope you get my point.
Posts: 867
Threads: 104
Joined: Jul 2010
Reputation:
0
How many manipulations with objects do you have in script?
Posts: 3
Threads: 1
Joined: Jun 2012
Reputation:
0
I'm using OnPlayerUpdate but is written optimally.
Cells string size too.
I use multiple timers, I'll try to pack them.
'manipulations with objects' = MoveObject, AttachObjectTo...? Yes, a lot.
Posts: 3,351
Threads: 780
Joined: Jan 2010
Quote:
Originally Posted by i64
I'm using OnPlayerUpdate but is written optimally.
Cells string size too.
I use multiple timers, I'll try to pack them.
'manipulations with objects' = MoveObject, AttachObjectTo...? Yes, a lot.
|
Doesnt mean if OnPlayerUpdate is written optimally,the callback itself checks every action of the player every second (i think),so create a custom callback and move your code from onplayerupdate to your custom callback).