Area and entity editing in Ember
I’d like to showcase some of the new editing functionality in the current Ember cvs. First off is the area editing.
There are many types of areas in the world. Some examples are the dirt area under the sty, the path to the village and the darker areas under the oaks. Each area belongs to an entity and is represented as a series of connected points which taken together create a 2d polygon. This polygon is then mapped to the terrain, replacing the regular grass or stone texture. With the new entity editor in Ember it’s now easy to create and edit areas in real time. These following screenshots shows how easy it is to edit an existing area.
The entity editor also allows you to easily create new entity attributes. This can be demonstrated by adding a new point to the existing area. Currently the area editing functionality only allows for changing the areas by changing the values of points manually, but in future versions it will contain a graphical editing components which will allow for users to drag and drop points with their mouse.
The other functionality I wanted to showcase is the ability to in real time see how changes to entities are reflected in the clients. In this case I’m editing a boulder. The boulders come in four different styles, uninspiringly named “a”, “b”, “c” and “d”. When we change this value in the entity editor, a request for this change is sent to the server. The server performs the update and sends an update op back to the client. Ember sees this update and queries its modelmapping engine, which contains rules for how models and materials are mapped to entity attributes, and performs the necessary visual changes. The modelmapping system is totally rule based and doesn’t depend on any scripting behaviour. And example of the format can be seen here. This decoupled system is very powerful and flexible, but also the main reason that Ember haven’t had support for something as seemingly basic as editing the appearance of entities until now. Now that all the underlying technology is in place can we begin leveraging it to do some very advanced stuff.
I’ve also began keeping a personal development blog. My intention is to fill it with the daily Ember developments.









