Packet Event
This page covers the API Reference for the ‘PacketEvent’ instance.
Fire()
Section titled “Fire()”Sends data to the opposite side.
Signature
PacketEvent:Fire(recipient: Player | {Player} | nil, parameters: T)Paramaters
- recipient - Sends to one player or if a table of players is passed it sends to all the players inside the table.
- parameters - Event Data
Connect()
Section titled “Connect()”Creates a listener for incoming packets.
Signature
PacketEvent:Connect(callback: (Player, T) -> ()): RBXScriptConnection?Paramaters
- callback - Function called when packet is received
Returns
RBXScriptConnection
