Weird stuff happens

So this is what I see .

Client Window

  1. Can see the platform moving.
  2. Can jump on the platform but fall through.
  3. Can walk through the platform.
  4. Can’t move into space where the platform was originally located.
  5. When the server dude jumps onto the platform he disappears from the client viewport!

Server Window

  1. Platform remains stationary
  2. Can jump onto the platform
  3. Can see the client dude in the correct position

Explanation
The client updates the moving platform and that is rendered correctly in the client window. However, all the physics stuff and interaction with the other actors in the world is wrong because the server thinks it is in a different position and the server’s view of the world is correct.

The server renders the platform in its original location and this does not change. So all interactions on the server with the server dude are consistent. Physics wise the server will not allow the client dude to move into the space occupied by the platform.

So it appears the physics ‘laws’ are performed on the server and not on the client and because the server has the cube’s location unchanged it does not ‘replicate’ this to the client.

I’m not sure I can explain why the server dude disappears from the client viewport.

2 Likes

The client is running a local simulation, that is updated by the server when relevant information changes. And this is why multiplayer gets straight up weird a lot. The simulation keeps going with it’s data, while the server sends corrections to it, like another universe occasionally steps in and corrects what you got wrong. And because you want to limit the data sent, you don’t just update the whole universe all the time… Welcome to the wonderful world of multiplayer.

1 Like

The server dude disappears because he wanted some cookies. There’s no other explanation :wink:

1 Like

Privacy & Terms