Hey folks. I'm looking to use Bevy for a multiplayer game I'm working on. The game will have server side authority with client side prediction (similar to the gdc talk for overwatch networking).
The gist is as follows:
- client sends inputs to server for
tick: n - server receives inputs for all clients (with some buffering) that it manages
- server simulates
tick: nand sends world state back to client fortick: n - because of latency, client receives server state for
tick: nwhen the client is attick: n+delta - client re-simulates from
tick:n --> tick:n+deltaall at once and applies that new, corrected state
My main questions are:
- Is a SubApp with some custom scheduling the right way to handle the re-simulation? I.e. Copy relevant chunks from main app to a sub app running all of the same systems relevant to the simulation. Run from
tick:n --> tick: n+deltaas fast as possible. Copy chunks back into the main app. - Can I force this re-simulation to run entirely before the main app's FixedUpdate tick?
Loving Bevy so far, thanks for the hard work!