Open Tofaa2 opened 2 months ago
I really like this suggestion. The current event manager does the job, but this would be a huge improvement. Especially since we are moving more and more towards projects unshading PacketEvents, and thus the event manager becomes more important!
Is your feature request related to a problem? Please describe. Nope
Describe the solution you'd like I think it'd be much more usable if event listener priorities were redone to just an int and compared via Integer.compareTo, and EventManager, rather than being a standalone class would be a creatable class that would have its own EventManager children and a parent, also allowing filtering certain events from a certain event node/manager in the tree.
Example structure pe-event-manager: my-plugin-event-manager: (priority 2) filter: some delegate listeners:
listeners:
The my-plugin-event-manager would filter according toa delegate and has its event listeners ran exclusively if the event filter is true. Each node and listener could have their own priority, or only the nodes would have priority