[ENet-discuss] ENET_EVENT_TYPE_DISCONNECT with peer address == 0

Paul Collier paching at gmail.com
Tue Jul 4 09:04:54 PDT 2006


Hello,

That's funny, I could swear that the address and port data were intact in my
disconnect events... oh well. Anyways, it's recommended that you use
peer->data (void pointer) to identify and distinguish your peers. Just point
to some custom structure with your application data.

Hope this helps,
- Paul


On 7/4/06, Intripoon <intripoon at gmx.de> wrote:
>
>
> Hi !
>
> I just started to use Enet. While evaluating enet for my needs, I wondered
> about this:
>
>
> "ENET_EVENT_TYPE_DISCONNECT     a peer has disconnected.
>
> This event is generated on a successful completion of a disconnect
> initiated
> by enet_pper_disconnect, if a peer has timed out, or if a connection
> request
> intialized by enet_host_connect has timed out. The peer field contains the
> peer which disconnected. "
>
>
> But if I get a ENET_EVENT_TYPE_DISCONNECT, event.peer->address.host and
> event.peer->address.port are 0. How am I supposed to recognize the peer
> that
> disconnected? Directly comparing the event.peer pointer instead?
>
>
> Best regards
>        Marc
>
> _______________________________________________
> ENet-discuss mailing list
> ENet-discuss at cubik.org
> http://lists.cubik.org/mailman/listinfo/enet-discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.cubik.org/pipermail/enet-discuss/attachments/20060704/c65c434c/attachment.htm 


More information about the ENet-discuss mailing list