junkdog / artemis-odb

A continuation of the popular Artemis ECS framework
BSD 2-Clause "Simplified" License
779 stars 113 forks source link

Add annotation driven aspects. #514

Closed DaanVanYperen closed 5 years ago

DaanVanYperen commented 6 years ago

As part of some fluid enhancements introducing annotation driven aspects on BaseSystem. Does not replace the regular aspects. As with all fluid features it shaves off some boilerplate.

@All({FlightPattern.class, Physics.class})
@Exclude(Frozen.class)
public class FlightPatternControlSystem extends FluidIteratingSystem {

Recycles some annotations from @GMWolf's (very cool!) https://github.com/GMWolf/artemis-odb-eeel for aspect metadata with concepts from https://github.com/junkdog/agrotera.

Just need to contact @GMWolf to see if he's ok with a couple of the annotations being absorbed into core before we release. Otherwise we'll have to pick other names from the annotations.

GMWolf commented 6 years ago

This looks like a great feature!

I would be glad to have the annotation be absorbed into core. If the annotation target still includes methods, it should not really interfere with EEEL.