Closed junkdog closed 9 years ago
More of a utility manager to cut down on some boilerplate. I think I had something more specific in mind, but can't remember what atm...
yes, something similar - or go with DI.
I tend to keep the assets reference components. they're handy to keep when serializing.
closing this as it's too easy to roll in project code; not all use-cases necessarily fit it, so I'll just leave it be. This is what I'm doing in the current project:
util.subscription( // util = EntityUtil extends Manager
all(Size.class, TextureReference.class),
new SubscriptionAdapter(world) {
@Override
protected void inserted(Entity e) {
assignSprite(e, textureReferenceMapper.get(e));
}
});
Shouldn't a users systems/managers already do this by means of the existing create/update/delete callbacks? (populate transient aspects of component model?)