OnPlayerUpdate or a timer? -
MarinacMrcina - 30.06.2012
Hi I have started to make an anticheat.Would using OnPlayerUpdate lag the server too much or should i put it in a 1 second timer?
What would be better?
Re: OnPlayerUpdate or a timer? -
WillyP - 30.06.2012
I wouldn't be calling it almost all the time as the more players you have the laggier it will get. Just try some testing of your own to find the best interval timing.
Re: OnPlayerUpdate or a timer? -
ivanVU - 30.06.2012
Napravi jedan globalan timer, od jednog timera nece lagati server.
Make one global timer, server won't lag of one timer..
Re: OnPlayerUpdate or a timer? -
.FuneraL. - 30.06.2012
OnPlayerUpdate Lagging server for many players, Timer Won't lag Because it is defined for each player
Re: OnPlayerUpdate or a timer? -
milanosie - 30.06.2012
Quote:
Originally Posted by .FuneraL.
OnPlayerUpdate Lagging server for many players, Timer Won't lag Because it is defined for each player
|
Complete nonsense,
Onplayerupdate is told to lag because it is basically a very fast timer,
Its basically something like this:
pawn Код:
SetTimerEx("OnPlayerUpdate", 62, true, "i", playerid);
And it will only lag if big operations are done at the OnPlayerUpdate, like file writing/loading, checking hundreds of variables, etc..
A timer would be a better choice, because you do not need to check for hacks 16 times a second,
A time of 2500 would be fine for an anti cheat, while OnPlayerUpdate uses around 62-63...
Respuesta: OnPlayerUpdate or a timer? -
Megalock - 30.06.2012
I believe that with a timer, it would be better and easier , not represent so much load.
Re: OnPlayerUpdate or a timer? -
Mean - 30.06.2012
Quote:
Originally Posted by milanosie
Complete nonsense,
Onplayerupdate is told to lag because it is basically a very fast timer,
Its basically something like this:
pawn Код:
SetTimerEx("OnPlayerUpdate", 62, true, "i", playerid);
And it will only lag if big operations are done at the OnPlayerUpdate, like file writing/loading, checking hundreds of variables, etc..
A timer would be a better choice, because you do not need to check for hacks 16 times a second,
A time of 2500 would be fine for an anti cheat, while OnPlayerUpdate uses around 62-63...
|
Not really, OnPlayerUpdate is always different. It's not always the same.