Skip to content

Modules

zyktex edited this page Jun 22, 2020 · 1 revision

Module Base Class

All modules extend the base abstract module class. The base class contains certain methods, such as the onEnable(), onDisable(), and onTick() methods. The module manager calls these methods when appropriate, and therefore removes the need to create event handlers for common events such as these.

Module Manager

The module manager manages the modules. When the client is loading, it automatically detects all modules and adds them to a module list. Every time a module is enabled, it subscribes all the event handlers, and unsubscribes them whenever a module is disabled. Moreover, every ClientTick, it invokes the onTick() method. Moreover, the manager has methods to get modules based on their name, or get settings from the module.

Clone this wiki locally