rustecs icon indicating copy to clipboard operation
rustecs copied to clipboard

Systems support

Open hannobraun opened this issue 11 years ago • 0 comments

Preliminary support for systems has been added: https://github.com/hannobraun/rustecs/blob/master/rustecs/tests/systems.rs

I think this goes in the right direction, but isn't really usable yet. There are still a few things missing before the feature can be considered complete:

  • [x] An Event enum should be generated with variants for each declared event type. I'd like to pass on the event into the systems, and I think this is the best solution to achieve this in a type-safe way.
  • [x] The event object passed to trigger should be passed on to the triggered systems.
  • [ ] A Control should be passed into each system. The control's apply method should be called after all systems have run.
  • [ ] Usage should be documented in the README.

hannobraun avatar Oct 31 '14 14:10 hannobraun