SA-MP Forums Archive
Connection Lags - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Connection Lags (/showthread.php?tid=188220)



Connection Lags - Arrows73 - 06.11.2010

Hi,
When players connect, they cause a server lag which lasts for 2-3 seconds.
This occurs after the player gets the 'Connecting to <ip>...' message and ends when he is fully connected (Connected to <ip>).
To fix this I have already tried to call OnPlayerConnect just when the player chooses the class which is described here:
https://sampforum.blast.hk/showthread.php?tid=184128

This fixes the lags but it caused some serious bugs in the script and before trying to 'adapt' the script to this, I would like to know if there are better ways to prevent connection lags which are used more frequently

BTW: The lags are not caused by the script / by the code which is in OnPlayerConnect.

Thanks in advance!