Allow the client to send movement hints

Registered by Erik Ogenvik

To allow for a more smooth experience on the client we should allow for "movement hints" to be sent.

To illustrate, I'll first describe the problem:
When the client moves it first sends a "move" op with a specific velocity. The client will use the velocity to predict where the entity should be at any given frame. When the client then stops it sends a new "move" op with a zero velocity. The server then processes this and sends back an op with the final position of the entity.
The problem is that due to network latency and other time related issues the position where the client predicted the entity to be at will almost always differ from where it actually ended up. The result is that the client will always experience a small adjustment of the view whenever movement stops. (This can be alleviated to some degree by instead smoothly adjust the entity position on the client, but that will also be disruptive to the player in the long run.)

To handle this, a "movement hint" could instead be sent from the client whenever the velocity changes. The hint specifies where the client thinks and wishes the entity to be. The server will consider the hint and try to adjust the velocity of the entity so that it actually ends up where the client thinks it should be, if possible. Note that the server still is the only authority; movement will still happen given the usual constraints.

In this model movement works just as above, but at the last stage, when the client stops, it also sends a position value indicating where it wants the entity to be when it stops. The server takes this value into account and provides a new movement op which will make the entity stop at the requested position, if possible. The end result is that the client won't experience any difference between where it did stop client side and where the server made the entity end up.
Other clients will however see a slight sliding motion. This should in most cases be rather small and not noticable.

The exact format for this in Atlas needs to be decided.

Blueprint information

Not started
Erik Ogenvik
Erik Ogenvik
Needs approval
Series goal:
Milestone target:

Related branches




Work Items

Dependency tree

* Blueprints in grey have been implemented.

This blueprint contains Public information 
Everyone can see this information.


No subscribers.