Chickynoid networking help

Hi! I’ve been having a lot of fun with Chickynoid lately, but I’ve run into a problem that I can’t seem to find on the devforum.

I want to implement a mechanic in which you can click on the ground, and then you fling away from the direction you’re pointing at. The solution I’ve implemented using Chickynoid’s weapon system works fine, and it feels pretty smooth.

simulation.state.vel += ((direction * -50) + (Vector3.yAxis * 10))

This exact equation is fed to both the server and client (via ServerProcessCommand and ClientProcessCommand) and both call the same function. However, there seems to be something I’m doing wrong here.

The server keeps rolling back the client’s position to where the server believes the client should be. This creates jagged and unsatisfying movement, as you get teleported backwards whilst you are mid-air. I’ve debugged this on both the server and the client and their variables seem to be synced.
combined
Note the frequent yellow spikes in the corner.

I’ve tried turning it into something more akin to JumpPad (using :RegisterMoveState), but it had the same rollback problems as before. My strategy to fling the player is by adding directly to the Simulation’s velocity, using the camera’s direction as the launch direction. Adding to the Simulation’s velocity does seem to have an impact on the rollback frequency, as when directly setting the velocity, the rollback is lessened, but not completely eliminated.

simulation.state.vel = ((direction * -50) + (Vector3.yAxis * 10))

combined
Note the occasional yellow spikes in the corner.

I’m confused, as the JumpPads and general jumping work fine, but the tool that I’m creating is being finnicky.

1 Like