0 Members and 1 Guest are viewing this topic.
Sounds like the soldat.pl lobby website could possibly use this with clientside javascript.
GJI suggest to rename some fields:"OsType" "OSType""Ip" "IP""Wm" "WM""Be" "AC" (as it's called Anti-Cheat in Soldat client)
How about serving in-game players' nicknames? It was possible over TCPbut it worked pretty randomly (what actually discouraged me to implement anything with this thing).
Alternatively, I think it might be possible to use the tcp asset download port to grab logs/gamestat.txt without needing to authenticate. If this works then it would be possible to make this API interface provide players; however, this would only be on the individual server endpoints rather than the full list.
I'll see if I can implement support for that into this API on the server endpoints.
Quote from: jrgp on April 10, 2017, 07:37:17 pmAlternatively, I think it might be possible to use the tcp asset download port to grab logs/gamestat.txt without needing to authenticate. If this works then it would be possible to make this API interface provide players; however, this would only be on the individual server endpoints rather than the full list.Yep, this works for grabbing gamestat.txt: https://wiki.soldat.pl/index.php/Download_threadI'll see if I can implement support for that into this API on the server endpoints.
Just did it. If you tack on /players to the end of an individual server URL, it will attempt to download gamestat.txt from that server and show the parsed out players.
Great work, man! Now I have to think what to do with this API Most desirably a mobile app.
Nice to see an ongoing development. Good job
I just rewrote https://soldat.pl/en/lobby to hit this API directly via ajax, rather than the old implementation which was a php shim against the old protocol.
Quote from: jrgp on April 19, 2017, 05:23:55 amI just rewrote https://soldat.pl/en/lobby to hit this API directly via ajax, rather than the old implementation which was a php shim against the old protocol.Once you got there you could set default ordering by amount of players (descending obviously). It would make more sense in my opinon to get servers where people actually play on the top of the list.This should also be done in the Soldat GUI (game) I think. Ordering by players amount - not ping. It's not within your cup of tea though.A bit off topic here right now:I see that you've (just?) removed top bar with language switching as I proposed to do so long time ago because of unsupported translations etc. Note that main domain i.e.: https://soldat.pl/ points to https://soldat.pl/pl/ (where there's still that messy frontpage etc.) instead of https://soldat.pl/en/. Also, the background picture should be elevated.
Hmm soldat.pl shouldn't be redirecting directly to soldat.pl/pl/: $ curl -I https://soldat.plHTTP/1.1 302 FoundDate: Wed, 19 Apr 2017 16:07:32 GMTLocation: https://soldat.pl/en/
Sorting by players descending also makes sense for the site. Not sure about ingame because that way you might have really high ping servers at the top rather than ones that you'll be able to play on comfortably.
I'm getting a 403 forbidden code when I try to get a player list (with /players in url). Is this just for me or is it a problem with the API? Or maybe it's being worked on?
Quote from: pewpew on November 04, 2017, 08:45:58 pmI'm getting a 403 forbidden code when I try to get a player list (with /players in url). Is this just for me or is it a problem with the API? Or maybe it's being worked on? I've just checked and I also encounter this problem. E.g.: http://api.soldat.pl/v0/server/45.76.84.88/23075/players -> 403