I would like to announce the completion (or at least perfectly usable state) of my entity-component framework, Entreri. If you’re a fan (or not a fan) of R.A. Salvatore, you might get the pun on the name with the existing entity framework, Artemis.
The project is hosted on Google Code here: http://entreri.googlecode.com/
It will be hosted on one of the central Maven repositories soon enough, but is otherwise fully Maven enabled.
The API was designed to be clean and simple, although defining Component types can be a little complicated (which I will go into below). You create an EntitySystem and add Entitites to it. You add and remove Components from Entitites. Entities can be queried by sets of Components they must have, and by single component type. Each Component type is assigned a so-called TypedId that functions much like a .class handle but can be used for constant-time access of an entity’s components (1 if-branch and an array lookup).
Inspired by Riven’s MappedObject’s library, all component data is packed into primitive arrays. The API for this is all in Java and does not use byte-code transformation. This does make the definition of Components a little more complicated than just defining fields, getters, and setters but it has essentially the same performance benefits of using the MappedObject approach.
It also allows for dynamic decoration of new properties onto a Component type such that all components of a given type in a system can be updated to have an extra “vector” or “matrix” or “X” field. This is primarily useful for caching internal data by each controller that processes the system.
Although it is fully java-doc’ed, it does not have any getting-started information. I will be adding that soon, hopefully, otherwise questions can be asked here. I hope people are able to find it a useful tool if they are interested in exploring an entity-component design in their game and are looking for an alternative to existing frameworks.
Thanks