Answer the question
In order to leave comments, you need to log in
Serialization and deserialization of commands, how to do it right?
Greetings.
I need to make a server for multiplayer game. I'm stuck on the fact that I don't know how to properly implement serialization and deserialization of commands. That is, we have a client that must send a collection of various commands in the current frame. For example: movement of object with ID1 to point Vector2(10,15), movement of object with ID2 to point Vector2(10,10), object with ID3 uses ability with ID385. The question is how can I organize the transmission of commands, and on the server side distinguish what kind of commands and their properties (ideally, I want to send this to the factory so that a new object is created there)
PS I understand that this can be done through xml or json, but since this is a multiplayer server, I'm looking for a binary serialization option.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question