44 points · by smig0 · 1y ago · 20 comments
I'm using ENet for my RTS project and found that Steam's networking code offers many of the same features offered by ENet (including the reliable, in-order delivery of packets, which is invaluable for an RTS Game). I was able to abstract things out so that my game uses ENet on LAN games and Steam networking for online games, and the rest of the game code is none the wiser.
While I think gdscript is largely a mistake and I look forward to feature parity in the C# interface, I'm still very excited to see all the projects coming out of Godot developers today.
Initially the move to godot was because I wanted sovereignty over the future of my projects.
But Godot is genuinely a delight to work in. If you're not making AAA games in a massive enterprise, Godot is the right blend of tools provided and getting out of the way.
The core of Godot's netcode is way too minimal. It gives you a way to synchronize state and make RPC. That's it.
As the author mentions adding in the higher level functionality like prediction, rollback, etc is extremely complicated so it's nice that netfox takes care of a lot of that complexity.
Maybe I’m missing something, but wouldn’t you either want the input to drop or the rewind to not happen at some point? If my network is extremely laggy when I’m playing a multiplayer game I would expect that my attempt to hit an opponent wouldn’t still succeed 1+ seconds later when they have already moved and are no longer in a position to be hit.
It should be:
1. Client input is either dropped or the input is applied but in an unexpected position (because when the user input occurred the client visible state was wrong)
2. On correction, client is rubber banded into the correct positions to match server state; rollback/replayed with correction if the game is deterministic
3. Server-authoritative; if it never reaches the server, the input never existed.