SA-MP Forums Archive
change maxplayers - 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)
+--- Thread: change maxplayers (/showthread.php?tid=589466)



change maxplayers - s3ek - 19.09.2015

how i can change maxplayers .. no restart server ?


Re: change maxplayers - xVIP3Rx - 19.09.2015

Without restarting the server, Not possible.
You have to close the server, change the server.cfg or the define and restart it.


Re: change maxplayers - s3ek - 19.09.2015

ok thx


Re: change maxplayers - Michael B - 19.09.2015

Actually, you can decrease the server slots by adding NPCs. One NPC connected to the server decreases the maxplayers limit by one. However, I don't know any method to increase the slots without restarting the server. Probably by kicking those NPCs?


Re: change maxplayers - Abagail - 19.09.2015

YSF has a function for this.

https://sampforum.blast.hk/showthread.php?tid=513499

Quote:

native SetMaxPlayers(maxplayers);
native SetMaxNPCs(maxnpcs);




Re : Re: change maxplayers - KillerDVX - 19.09.2015

Quote:
Originally Posted by Michael B
Посмотреть сообщение
Actually, you can decrease the server slots by adding NPCs. One NPC connected to the server decreases the maxplayers limit by one. However, I don't know any method to increase the slots without restarting the server. Probably by kicking those NPCs?
No, he can't increase it without restarting the server.