Closed OfficerFields closed 1 year ago
not all servers send a list of players
I‘m aware of that, but this issue happens in my case for Insurgency, Team Fortress 2 and 7 Days To Die. Those servers used to send a list of players via GameQ. I know that there was an update to Valve‘s Source serverquery which was implemented in GameQ, but it still does not work for me.
try this for source protocol
protected $packets = [
self::PACKET_CHALLENGE => "\xFF\xFF\xFF\xFF\x56\x00\x00\x00\x00",
self::PACKET_DETAILS => "\xFF\xFF\xFF\xFFTSource Engine Query\x00%s",
self::PACKET_PLAYERS => "\xFF\xFF\xFF\xFF\x55%s",
self::PACKET_RULES => "\xFF\xFF\xFF\xFF\x56%s",
'details_old' => "\xFF\xFF\xFF\xFFTSource Engine Query\x00",
];
Thank you for the suggestion @Ruslan-700. I tried it, unfortunately there is still no player reporting.
Unfortunately, this breaks games with a new protocol, such as rust. Need to find another solution
7 days to Die has never transferred the player list should be tested
Ruslan-700 @.***> schrieb am Sa., 1. Okt. 2022, 14:40:
Unfortunately, this breaks games with a new protocol, such as rust. Need to find another solution
— Reply to this email directly, view it on GitHub https://github.com/Austinb/GameQ/issues/663#issuecomment-1264353093, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASIOMUHJHCECDAGFQU4AO5LWBAWNHANCNFSM6AAAAAAQNLA5OE . You are receiving this because you commented.Message ID: @.***>
https://developer.valvesoftware.com/wiki/Server_queries#Response_Format
Servers may respond with the data immediately. However, since this reply is larger than the request, it makes the server vulnerable to a reflection amplification attack. Instead, the server may reply with a challenge to the client using S2C_CHALLENGE ('A' or 0x41). In that case, the client should repeat the request by appending the challenge number. This change was introduced in December 2020 to address the reflection attack vulnerability, and all clients are encouraged to support the new protocol.
We need to make the first request without a challenge, if we receive a challenge in response, we make a second request with a challenge
https://pastebin.com/MCeXCGWR this is temporary solution, you can't call it beautiful or optimal
7Days to die not work!
"players":[{"id":0,"name":"","score":0,"time":2004.292724609375,"gq_name":"","gq_score":0,"gq_time":2004.292724609375},{"id":0,"name":"","score":0,"time":159.89271545410156,"gq_name":"","gq_score":0,"gq_time":159.89271545410156}]
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Not stale
Did some digging and looked at 7 days specifically using this server list - https://7daystodie-servers.com/. Many servers would not query using the new or old info calls. But those that did work all of them required the updated protocol request using the changes here. Also, 7 days has never returned the player names. None of the tests created for the game have player names in the responses. Many games do not provide player name in the A2S_Players response for various reasons. Looking at the raw response the player name is not in there to be shown from any 7 days server I was able to get a response from.
As for TF2: every server queried using the latest version from v3 branch worked and showed player names in the responses. As for Insurgency: every server queried using the latest version from v3 branch worked and showed player names in the responses. In all cases these are servers listed publicly from BattleMetrics.
As to making multiple queries sending the INFO call without the challenge and then sending it with if needed is a waste of time and processing. If the server is old it will probably just drop everything after the packet request type. If not then an override can be built into the server classes that require the old query way if needed.
Please check against the last available version in v3 branch (not releases as those tend to be behind). If you have an issue please open a new issue since this one is cluttered with different issues that are not related (i.e. no information vs no player information).
Hi there,
I have a problem with all servers that use the A2S protocol. I'm using the latest GameQ version and I can only query my A2S servers when I set the environment variable "STEAM_GAMESERVER_A2S_INFO_STRICT_LEGACY_PROTOCOL" to 1 (Windows Server 2019). After that, the servers show as online, but I can't get the list of players (the number of players works, actually).
Sorry if I missed something to set up. Any idea what might cause the problem?
Thanks!