-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
A2S_RULES contains binary data for Arma 3 servers #67
Comments
I've implemented this now in python-a2s using the encoding parameter. Sorry for the (very) late response. |
How in the heck do I actually use a2s.rules to get the rules decoded in the correct way? I'm trying to do this with DayZ and that protocol should be the same as Arma 3. |
Pass |
Hello there! Oh my, it's been almost 4 years since I've written here :) @Yepoleb what you're linking to is a branch that parses A2S_INFO for arma keywords found in that packet and nothing else. The rules that gust4vsson is talking about are a completely different set of data. The Arma 3 rules stored in the A2S_RULES are described here: https://community.bistudio.com/wiki/Arma_3:_ServerBrowserProtocol3 The only thing missing there is a few flag values of the DLC flags, AFAIR, but they are rather easy to figure out. However, I have to admit, DayZ rules may be completely different as they have completely revamped the multiplayer module, I think. But anyway, you can check how much different they are by looking at the link I gave you. You can parse these packets using either Construct or Kaitai. |
Oops, guess I need to practice to read again. Sorry for the confusion. |
The Arma 3 game uses A2S_RULES entries to store additional data about the server, as described here:
https://community.bistudio.com/wiki/Arma_3_ServerBrowserProtocol2
In short, because some arbitrary (binary) data can be passed in those rules, there is a risk of those rules forming an incorrect UTF-8 string.
How can I best work around the issue of python-vale always trying to
decode('utf8')
the rules contents without breaking the whole library? (RulesResponse
is declared as containingStringField
s)I'd be interested in producing a non-intrusive solution that could then be merged back. I'm not sure that changing the declaration of RulesResponse to contain raw bytestrings a good idea, for example.
The text was updated successfully, but these errors were encountered: