22#ifndef BACKENDS_NETWORKING_ENET_HOST_H
23#define BACKENDS_NETWORKING_ENET_HOST_H
33#define ENET_EVENT_TYPE_NONE 0
34#define ENET_EVENT_TYPE_CONNECT 1
35#define ENET_EVENT_TYPE_DISCONNECT 2
36#define ENET_EVENT_TYPE_RECEIVE 3
38#include "common/system.h"
39#include "common/str.h"
40#include "common/debug.h"
99 bool send(
const char *data,
int peerIndex,
int channel = 0,
bool reliable =
true);
void disconnectPeer(int peerIndex)
Common::String getPacketData()
uint8 service(int timeout=0)
bool sendRawData(const Common::String &address, int port, const char *data)
Host(ENetHost *host, ENetPeer *serverPeer)
bool send(const char *data, int peerIndex, int channel=0, bool reliable=true)
bool connectPeer(const Common::String &address, int port, int timeout=5000, int numChannels=1)
int getPeerIndexFromHost(const Common::String &host, int port)