GitBrincie212 / Apel-Mod

Apel is a library that brings particle animations to the table with flexible behaviour and a clean developer interface. It promises also lots of predefined shapes & paths to help the developer on their particle scene
Other
2 stars 1 forks source link

Allow multiple interceptor actions at each hook point #34

Open DarthSharkie opened 2 months ago

DarthSharkie commented 2 months ago

Currently, each extension point (beforeDraw, afterDraw, beforeChildDraw, afterChildDraw) allows for a single function to be assigned. It may be useful to allow multiple functions to be assigned, so provide facilities to run multiple functions when reaching an extension point. Implementation options vary, either maintaining a List of interceptor functions or providing the ability to compose them (similar to how Java allows composing Predicate instances). The priority is ensuring a simple, intuitive API.