Comment 1 for bug 178576

Revision history for this message
Erik Ogenvik (erik-ogenvik) wrote :

This is because the cyphesis server currently only has very rudimentary collision detection. Al knows more on how to tackle this.

However, it also touches on how Ember allows for object movement. Currently movement of entities in Ember works like this:
1) When clicking on any entity except the world a "move" menu option is presented.
2) After choosing "move", Ember lets the player move the object on the client. No information of this is sent to the server yet.
3) After the player has moved the object he/she presses the left mouse button (or esc to abort the movement). An op is sent to the server telling it to try to update the "pos" attribute of the moved entity. Ember also starts a three second timer event.
4) If the server allows the movement, the updated "pos" attribute is transmitted to all clients (including our own), and the timer event is aborted. However, if the server doesn't allow the movement, nothing is transmitted, and the timer event will trigger. This event will reset the position of the entity to the original one. You can see this behaviour if you try to move a large structure such as a tree when logged in as a normal user (an admin user can move everything).

This works pretty well, but it's a bit strange that the "move" option appears on stuff that very much can't be moved by the user (any large structure). If I remember correctly the ability to move something is determined by the mass of the entity being moved. So if the client knew the max mass for movable entities for the current avatar, we could disable the "move" option in the Ember menu for nonmovable entities. I assume it's inferred from the "strength" attribute?