I'm making a multiplayer game. I'm just about done. I've got the mechanics worked out, I just need to handle latency in some way.<p>The game: tron lightcycles, but to turn, the user must solve a math problem.<p>What I've tried:<p><pre><code> 1. Update game state for every player every time either player changes direction. Why didn't it work? Not the best way to handle it (also got that math wrong somewhere, and the undraw function would leave gaps in player trails)
2. Update game state for every player every 100ms. Why didn't it work? Player 1 and player 2 are running different instances of the class that is supposed to update game state, and I can't share the instance between the two
</code></pre>
Stack: Python/Django, PostgreSQL, javscript/jquery<p>I need help. Can anyone help?
Here [1], Ricky "Infil" Pusch explains the two more used methods to workaround lag in fighting games.
I'm not sure if this will be useful in your case, but it's a great read anyway. I'm not a gamer but really enjoyed reading it.<p>[1]: <a href="http://ki.infil.net/w02-netcode.html" rel="nofollow">http://ki.infil.net/w02-netcode.html</a>