Continuation/fork of port by nadako. Entity component framework originally written in ActionScript 3, see http://www.ashframework.org/

component, entity, game, system
haxelib install hx-ash 0.1.2


======= hx-ash

Build Status

Fork/continuation of https://github.com/nadako/Ash-HaXe.

#The original repository has continued development again, rendering this continuation obsolete.

This is a HaXe port of the awesome Ash entity component framework by Richard Lord (http://www.ashframework.org/). It leverages HaXe's great cross-platform portability and runs on Flash, JavaScript, C++, Android, iOS and so on. Also it uses much static typing features of HaXe, allowing more mistakes to be detected at compile time instead of runtime than in original ActionScript 3 version.

Check out original Ash website for great articles on entity frameworks and game development.


  • Port serialization stuff. This is kind of tricky because original Ash uses reflection and we are trying to avoid it, so we gotta be smart about macros.
  • Refine access control for private classes and fields. Original Ash used internal class/field feature of AS3, in Haxe we need to use ACL metadata.
  • Review generacted code on performance, add inlines (especially important to inline iterators)


haxelib install hx-ash

CHANGES from original port:

  • Dead Code Elimination fix by eliasku.
  • Unit tests using std haxe.unit. Allows for automated travis-ci builds. Note that some of this port was done automatically by some scripts (some beauty flaws in code).
  • Entity unique IDs that can be used to retrieve them, contributed by theor.
  • Optional components in nodes using @optional attribute - null if not present in the entity, does not affect the entity matching by a system
  • Support for Java target. Useful if you want to target dalvik.

Note, with updates to hamcrest (used for unit testing) and haxe, the java and cpp build targets are not guaranteed to work and have been excluded from unit tests.


  • Maybe make the switch to MSignal.
  • Check whether example is still functional


Dan Korstelev, Elias Ku, Guido Zuidhof, theor