Devlog | M3a

The bug that wasn't in the code I blamed

The graybox block in Play

This was the milestone where OVERTIME stopped being a cube. There's now a character you can run and jump with, a third-person camera, and a small graybox city block with buildings, a kerb and a crate to bump into.

Movement is predicted. Your client moves you straight away and the server checks it afterwards, because in an MMO the server has the final say. Getting that working was the easy part.

Then I started playing, and the character was jumping between frames. Not by much, but you can't unsee it.

I was sure the server was the problem. It corrects the client's position, so it seemed obvious that those corrections were pulling the character around. I looked at only correcting when the difference was large. It kept jumping.

The clue came from the Scene view. When I watched the character there, it looked perfectly smooth. Only the Game view stuttered. So the character was fine. Whatever was looking at it wasn't.

The camera was running one frame behind the player. Unity's DOTS presentation step runs after LateUpdate, so the camera was following where the player used to be. Moving the follow target earlier in the frame took the wobble from 73 mm to zero. I added a little position damping for feel, and for the first time, moving around felt good.

Client prediction now stays within 1 mm of the server, so the thing I blamed was doing its job all along.

The lesson: when something looks wrong, check where you're looking from.