SA-MP Forums Archive
Web API and Players - 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: Web API and Players (/showthread.php?tid=536965)



Web API and Players - maxisaibot - 13.09.2014

Hi!

I'm using some PHP web api. But samp not showing player names over 100 players. You have any idea for posible? with server side changes or cfg commands ?


Re: Web API and Players - Lordzy - 13.09.2014

It's a limitation which will not be reporting about the player's details if the player count goes beyond 100. However, it's possible if you get it server sided too. Under OnPlayerConnect and OnPlayerDisconnect, send data to the webpage in regarding to update the player list.


Re: Web API and Players - MicroD - 13.09.2014

Use sockets.
https://sampforum.blast.hk/showthread.php?tid=333934


Re: Web API and Players - CutX - 13.09.2014

there's kinda workaround you could do.

let's assume that you're saving player account details in a MySQL db.
What we do now is add a new entry to every account, it'll be a SmallInt
and lets call it "connected". the value of "connected" is set to 1 once some1
log in to his account and to 0 once that player disconnects.

we could then use that new entry as indicator for a player being online/offline.
we don't need to use the web API anymore, it'll be simple php querying your player db for that entry
in every row. like this, it doesn't matter if theres 50 or 500 players online. there's no limit using that method.