Difference between revisions of "BKCommonLib/EventsAndListeners"
Jump to navigation
Jump to search
(Created page with "« Go back ==Introduction== BKCommonLib keeps track of several server events that can not be monitored using Bukkit alone. The following events (and listeners...") |
m (Change old dev.bukkit.org wiki link to internal wikilink) |
||
(One intermediate revision by one other user not shown) | |||
Line 13: | Line 13: | ||
==Packets== | ==Packets== | ||
− | The following events are available when registering a [ | + | The following events are available when registering a [[BKCommonLib/Packets|PacketListener]]: |
* [https://github.com/bergerkiller/BKCommonLib/blob/master/src/main/java/com/bergerkiller/bukkit/common/events/PacketReceiveEvent.java PacketReceiveEvent] when a packet is received from the client | * [https://github.com/bergerkiller/BKCommonLib/blob/master/src/main/java/com/bergerkiller/bukkit/common/events/PacketReceiveEvent.java PacketReceiveEvent] when a packet is received from the client | ||
* [https://github.com/bergerkiller/BKCommonLib/blob/master/src/main/java/com/bergerkiller/bukkit/common/events/PacketSendEvent.java PacketSendEvent] when a packet is about to be sent to the client | * [https://github.com/bergerkiller/BKCommonLib/blob/master/src/main/java/com/bergerkiller/bukkit/common/events/PacketSendEvent.java PacketSendEvent] when a packet is about to be sent to the client |
Latest revision as of 00:51, 26 September 2023
Introduction
BKCommonLib keeps track of several server events that can not be monitored using Bukkit alone. The following events (and listeners) are available:
Entities
The following entity related events are available:
- EntityAddEvent - when an entity is added to the server
- EntityRemoveEvent - when an entity is removed from a world
- EntityRemoveFromServerEvent - when an entity is permanently removed from the server
- EntityMoveEvent - fired every tick to update entity movement. This event is optimized.
Packets
The following events are available when registering a PacketListener:
- PacketReceiveEvent when a packet is received from the client
- PacketSendEvent when a packet is about to be sent to the client
Internal
Developers should ignore these events, as they are mainly used to keep track of internal BKCommonLib changes:
- TimingsListener for keeping track of execution times on the server