So I really want to make a 3d online shooter with a rigidbody controller. I don’t use Photon or UNet, instead, I use custom-built package management & internet communication. Link to the tutorial I followed:
Since it’s basically my first experience with networking I wanted to ask for some advice. For example, I want to implement a server-authoritative game with a tickrate system (very similar to Valve’s netcode: Source Multiplayer Networking - Valve Developer Community). But I also need to do physics movement. So, is it okay if I send out server movement data in FixedUpdate() with a timestep of 0.015 seconds? Or is it better to have some kind of timestep variable and send out data in Update()? Also, right now, the script that takes player input and applies forces to player rigidbodies and sends out player positions back to the client(s) is attached to individual players, but I feel that this is not the best way to do that. In articles like this: https://codersblock.org/posts/unity-client-side-prediction/ the author, when doing input prediction, says that after receiving a server snapshot, he has to re-simulate the newer movements. How? Is he applying the forces again? I understand everything until the point when he stores input. (By the way, I know this article exists (In fact, I read it a lot of times) Client-Side Prediction and Server Reconciliation - Gabriel Gambetta)
Here, I uploaded my client and server to GitHub: https://github.com/spicymuffin/Backup-multiplayer-before-input-prediction
Help is appreciated. Thanks in advance!