registerPacketReceived

open fun registerPacketReceived(method: Any): PacketTrigger

Registers a new trigger that runs whenever a packet is sent to the client from the server

Passes through two arguments:

  • The packet

  • The event, which can be cancelled

Available modifications:

Return

The trigger for additional modification

Parameters

method

The method to call when the event is fired

Sources

Link copied to clipboard