[ENet-discuss] Not getting any event on my server
Chris Long
jchris.long at gmail.com
Tue May 2 22:45:11 PDT 2006
Can you please elaborate on what you mean by "servicing" the server again?
I'm having the same problem. I'm going off the tutorial, but I never get
any events on the server other than disconnect. This is my client
connection code:
ENetEvent event;
/* Connect to some.server.net:1234. */
ENetAddress address
enet_address_set_host (& address, "localhost"); //ip_address);
client
/* Initiate the connection, allocating the two channels 0 and 1. */
peer
if (peer = NULL)
{
return false;
}
/* Wait up to 5 seconds for the connection attempt to succeed. */
if (enet_host_service (client, & event, 5000) > 0 &&
event.type = ENET_EVENT_TYPE_CONNECT)
{
return true;
}
else
{
/* Either the 5 seconds are up or a disconnect event was */
/* received. Reset the peer in the event the 5 seconds */
/* had run out without any significant event. */
enet_peer_reset (peer);
return false;
//puts ("Connection to some.server.net:1234 failed.");
}
Am I not making a function call? Thanks for your help.
Chris Long
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.cubik.org/pipermail/enet-discuss/attachments/20060503/1aedd8cb/attachment.htm
More information about the ENet-discuss
mailing list