raknet.Send
Sends a bit stream.
Syntax
raknet.Send(bitstream: any, priority?: number, reliability?: number, channel?: number) -> nil
Parameters
| Parameter | Type | Description |
|---|---|---|
bitstream | any | The bitstream value used by the call. |
priority? | number | The priority value used by the call. |
reliability? | number | The reliability value used by the call. |
channel? | number | The channel value used by the call. |
Returns
| Type | Description |
|---|---|
nil | This function does not return a value. |
Description
raknet.Send is part of the RakNet library. RakNet helpers expose the client's network stream: packet hooks, capture controls and bitstream serialization.
The operation is performed immediately using the arguments supplied at the call site.
Example
local stream = raknet.new()
stream:WriteU8(1)
raknet.Send(stream)
Notes
- Packet hooks run on the network path and should return quickly.