-
Notifications
You must be signed in to change notification settings - Fork 0
Description
Hello,
It is surprising that you don't study too far from me, especially since you were a minecraft idol on hf for me when I was younger. ( I go to WIU ) but that is besides the point.
I was looking at the eventmanager and I get the basic use of it, however I don't feel as if I am properly implementing it. I am used to the basic module class that has onEnabled, OnDisable, OnTick etc.
Would having something like:
emitter.on(keyPressEvent.class, e -> this.onToggle(e.getKey()));
in the constructor of the module be the proper way to use this?
So then all I would have to do is in my main class just do something like
MyModule module = new MyModule() to have it registered.
Then in ontoggle the you enable or disable, so that when you enable that is when you register all other events as needed.
(I pm'd you on hf, but saw that it has been a really long time since you last posted, figured I'd ask on here)