Why, you ask? Because hey, you can never have too many. Actually, it was because I couldn't really wrap my mind around practical usage. I figured if I made my own I might truly grok it.
The code is short and readable (imho). Usage can be gleaned from the code. These are the available functions:
Code: Select all
les.s.set(of, sort, f(e) reqs, f(e, ...) code) -- creates a system
les.e.set({}) -- creates an entity, returns an eid
les.e.get(eid) -- gets an entity by eid
les.e.all(uid, reqs) -- returns a set of entities
les.e.del(eid) -- deletes an entity