What's more efficient?
#4

Definitely OnPlayerConnect() is the way to go, because there is no guarantee that any players are connected at all in OnGameModeInit(). It takes time to connect after a gamemode starts, so your players may not be connected yet.

And it is better to spread out the load of the server over time, rather than to call everything at once, because PAWN is single-threaded. So, calling your function 200 times in a loop will stop anything else from happening until the loop finishes. Calling your function once every time a person connects will be much more efficient for you.

~Cueball~
Reply


Messages In This Thread
What's more efficient? - by Danny_Costelo - 29.05.2009, 23:59
Re: What's more efficient? - by JoeDaDude - 30.05.2009, 00:06
Re: What's more efficient? - by Danny_Costelo - 30.05.2009, 00:37
Re: What's more efficient? - by Cueball - 30.05.2009, 00:45

Forum Jump:


Users browsing this thread: 1 Guest(s)