SDLNet.UDPSocket.bind:
Description:
public int bind (
int channel,
SDLNet.IPAddress address)
Bind the address 'address' to the requested channel on the UDP socket.
Parameters:
ptr: |
If the channel is -1, then the first unbound channel that has not yet been bound to the maximum number of addresses will be bound with the given address as it's primary address. If the channel is already bound, this new address will be added to the list of valid source addresses for packets arriving on the channel. If the channel is not already bound, then the address becomes the primary address, to which all outbound packets on the channel are sent.
|
ptr: |
If the channel is -1, then the first unbound channel that has not yet been bound to the maximum number of addresses will be bound with the given address as it's primary address. If the channel is already bound, this new address will be added to the list of valid source addresses for packets arriving on the channel. If the channel is not already bound, then the address becomes the primary address, to which all outbound packets on the channel are sent.
|
Returns:
This function returns the channel which was bound, or -1 on error.