M1 | M2 | 055 | 001
|Summary:||Moving sector improvements|
|Product:||Odamex||Reporter:||Dr. Sean <grandpachuck187>|
|Component:||Client||Assignee:||Odamex Bug Reporter <odamex-bug-reporter>|
Description Dr. Sean 2012-03-15 22:07:30 UTC
Sectors currently move very smoothly client-side with the exception of sectors that are moved by the local player. Example: Local player has a 250ms ping to the server and therefore is predicting his own movement 125ms ahead of the server receiving the movement input. The player opens a door and the prediction code begins opening the door immediately. If the door is moving up 4 units every tic, the player can successfully walk underneath the opening door 392ms later. However, when the server receives the player's input to open the door, it will send a message telling all clients to begin opening the door. So 250ms after the local player started to predict opening the door, he receives a message from the server to begin opening the door. Currently in Odamex, this causes the local player to put aside its initial prediction of the door and accept the server's state message for the door, essentially resetting the door to the state where it was when it began to open. This causes a visual jitter in the movement of the door and also causes the client to mis-predict his own position when he tries to move through the door since the client will think the door is at the wrong height in relation to his prediction.
Comment 1 Russell Rice 2012-03-22 15:18:22 UTC
I had a wild theory the other night as to why a jitter happens on a moving platform when a player is on it (it happens to doors/crushers too) A client only receives an update to a sector every so often, so the sector keeps moving clientside even if there are no updates, next it receives the update and therefore moves the sector back to the servers position (which is slightly in the past on the client) Is this correct?