gnet/enet timeout

BlitzMax Forums/BlitzMax Programming/gnet/enet timeout

pls(Posted 2006) [#1]
Hi folks.

I am using gnet on Su Doku Live (see http://www.deadpixelgames.com for details). I have seen some unexplained disconnects happen mid-game. My question is: what is the correct way of changing timeout values of the module?

I have browsed the source on enet c source, found the call with the timeout_ms parameter, but I was wondering is there is a better way of changing that value from bmax without hacking the base enet code. I see no obvious pathway to achieve that in the gnet functions documentation.

Changing the base enet code is really easy simply changing it to some hardcoded higher value is a terrible solution. What am I missing?

PLS


ozak(Posted 2006) [#2]
Can't you just set the timeout on the socket? Check the docs, as I'm merely pulling this from memory :)


GW(Posted 2006) [#3]
gNet has somekind of issue with clients just dropping the connection, for me I get no indicator that the client has dropped either. as an example, open up a host and client app in windowed mode on the same machine, then click and hold on the title bar of the client app and make it freeze, if you let go of the title bar after a few seconds the client will re-sync and keep going, but if its more than 5 or so seconds, the client app never syncs back up and acts like its disconnected. There is also no notice that i can find from the host that the client has dropped either.. :(


BinaryBurst(Posted 2011) [#4]
Yeah that's the same thing happens to me too. But this time I have tested on the field. I have a mutiplayer game and when I connect to somebody like 7 countries away from me , I lose him at the half of the game. It suddenly stops to sync.

Last edited 2011


YellBellzDotCom(Posted 2011) [#5]
I went with Raknet, easy to implement with all the goodies! Sync, discons, conns, messaging, etc.

Well, I shouldn't say easy, easy for most, but took me about a week to understand it.


gameproducer(Posted 2011) [#6]
I went with Raknet, easy to implement with all the goodies! Sync, discons, conns, messaging, etc.

Well, I shouldn't say easy, easy for most, but took me about a week to understand it.

Where can you get most up to date raknet wrapper for bmax?


YellBellzDotCom(Posted 2011) [#7]
This is the one I used. I tried others but I think Zeke had the easiest example that I was able to use to figure out how to put things together...

http://www.blitzbasic.com/Community/posts.php?topic=90121#1033433


gameproducer(Posted 2011) [#8]
I presume it's this file:
http://www.byrathon.com/zeke_raknet.zip

I never got this to compile for some reason. :/


gameproducer(Posted 2011) [#9]
ok, got it to compile. dunno what was wrong.

Last edited 2011


YellBellzDotCom(Posted 2011) [#10]
:)