Dealing with Latency in Networked Games

前端 未结 5 901
别那么骄傲
别那么骄傲 2020-12-04 11:25

I\'m thinking about making a networked game. I\'m a little new to this, and have already run into a lot of issues trying to put together a good plan for dead reckoning and

5条回答
  •  粉色の甜心
    2020-12-04 11:55

    You could try imposing latency to all your clients, depending on the average latency in the area. That way the client can try to work around the latency issues and it will feel similar for most players.

    I'm of course not suggesting that you force a 500ms delay on everyone, but people with 50ms can be fine with 150 (extra 100ms added) in order for the gameplay to appear smoother.

    In a nutshell; if you have 3 players:

    • John: 30ms
    • Paul: 150ms
    • Amy: 80ms

    After calculations, instead of sending the data back to the clients all at the same time, you account for their latency and start sending to Paul and Amy before John, for example.

    But this approach is not viable in extreme latency situations where dialup connections or wireless users could really mess it up for everybody. But it's an idea.

提交回复
热议问题