ENet  v1.3.17
Reliable UDP networking library
Functions
ENet global functions

Functions

void enet_deinitialize (void)
 Shuts down ENet globally. More...
 
int enet_initialize (void)
 Initializes ENet globally. More...
 
int enet_initialize_with_callbacks (ENetVersion version, const ENetCallbacks *inits)
 Initializes ENet globally and supplies user-overridden callbacks. More...
 
ENetVersion enet_linked_version (void)
 Gives the linked version of the ENet library. More...
 

Detailed Description

Function Documentation

◆ enet_deinitialize()

void enet_deinitialize ( void  )

#include <include/enet/enet.h>

Shuts down ENet globally.

Should be called when a program that has initialized ENet exits.

◆ enet_initialize()

int enet_initialize ( void  )

#include <include/enet/enet.h>

Initializes ENet globally.

Must be called prior to using any functions in ENet.

Returns
0 on success, < 0 on failure

◆ enet_initialize_with_callbacks()

int enet_initialize_with_callbacks ( ENetVersion  version,
const ENetCallbacks inits 
)

#include <include/enet/enet.h>

Initializes ENet globally and supplies user-overridden callbacks.

Must be called prior to using any functions in ENet. Do not use enet_initialize() if you use this variant. Make sure the ENetCallbacks structure is zeroed out so that any additional callbacks added in future versions will be properly ignored.

Parameters
versionthe constant ENET_VERSION should be supplied so ENet knows which version of ENetCallbacks struct to use
initsuser-overridden callbacks where any NULL callbacks will use ENet's defaults
Returns
0 on success, < 0 on failure

◆ enet_linked_version()

ENetVersion enet_linked_version ( void  )

#include <include/enet/enet.h>

Gives the linked version of the ENet library.

Returns
the version number