[ENet-discuss] ENET_DISCONNECT_EVENT

LoneSock lonesock at gmail.com
Fri Jan 20 13:16:34 PST 2006


I noticed that you are calling enet_host_service on the host...are you also
calling it on the client?

Jonathan
--
Piranha are people too.



On 1/20/06, Lee Salzman <lsalzman1 at cox.net> wrote:
>
> It sounds like you're not servicing the host for those 16,000 ms. That's
> pretty much what would cause that.
>
> Lee
>
> Doug Kimzey wrote:
> > After an eNet client establishes a connection to an eNet Host, the
> > client is disconnected after approximately 30 seconds.  We have traced
> > this on the host side to a call to enet_peer_reset in the
> > enet_protocol_check_timeouts(…) function:
> >
> >
> >
> >        if (outgoingCommand -> roundTripTimeout >= outgoingCommand ->
> > roundTripTimeoutLimit)
> >
> >        {
> >
> >           event -> type = ENET_EVENT_TYPE_DISCONNECT;
> >
> >           event -> peer = peer;
> >
> >
> >
> >           enet_peer_reset (peer);
> >
> >
> >
> >           return 1;
> >
> >        }
> >
> >
> >
> >
> >
> > In this case the roundTripTimeout equals the roundTripTimeoutLimit of
> > 16,000 ms (or 16 seconds).
> >
> >
> >
> > I have added a call from the client application to enet_peer_ping(…)
> > that is on a timer to fire every 2 seconds – but the disconnect still
> > occurs.  The host runs a perpetual loop that calls enet_host_service(…).
> >
> >
> >
> > Would you have any suggestions or recommendations?
> >
> >
> >
> > One thing I noticed from the Cube Legends source is that they added a
> > PING / PONG message so that whenever a PING message is received on the
> > server, it immediately does an enet_peer_send of a PONG message back to
> > the client.  Are there other and better ways to handle "keep-alive"
> packets?
> >
> >
> >
> > -Doug
> >
> >
> >
> >
> >
> > Doug Kimzey
> >
> > Software Developer
> >
> > DPRA DEFENSE SYSTEMS GROUP
> >
> > 10215 Technology Drive, Suite 201
> >
> > Knoxville, Tennessee 37932-3344
> >
> >
> >
> > Phone:   865.218.4237
> >
> > Cell:        865.382.0307
> >
> >
> >
> > Email:    doug.kimzey at dpra.com
> >
> > Home:     mdkimzey at comcast.net
> >
> > www.defensesystemsgroup.com
> >
> >
> >
> >
> > ------------------------------------------------------------------------
> >
> > _______________________________________________
> > ENet-discuss mailing list
> > ENet-discuss at cubik.org
> > http://lists.cubik.org/mailman/listinfo/enet-discuss
>
> _______________________________________________
> 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/20060120/19fb5290/attachment-0001.htm


More information about the ENet-discuss mailing list