Answer the question
In order to leave comments, you need to log in
How to avoid data loss in a multiplayer game?
We are developing a TBS game and have encountered a data loss issue. We use socket.io (WebSocket) to transfer data. How can we avoid data loss? Server: native node.js solution, client: Unity 5.5.0f3.
Answer the question
In order to leave comments, you need to log in
On the client: in case of non-delivery of data to the server, accumulate data and repeat sending again, including after reconnect.
On the server: in case of non-delivery of data to the client, accumulate data and repeat sending again, including after reconnect.
If I understood correctly, then you are faced with the fact that the IO socket periodically loses a message.
I've come across this and the only explanation I've found is that the io socket uses tsp as a message delivery guarantee, but does not provide a 100% delivery guarantee. Critical data should be confirmed through program logic, IMHO.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question