Masterserver forgetting about active gameservers? Timeouts?
Goto page Previous  1, 2
 
Post new topic   Reply to topic    Unity Community Index // Multiplayer Networking
View previous topic :: View next topic  
Author Message
jashan



Joined: 09 Mar 2007
Posts: 1546
Location: Munich, Germany

PostPosted: Mon Apr 21, 2008 3:12 pm    Post subject: Reply with quote
Well, at the moment, I'm going at a rate of 10 seconds (or maybe even 5), but less frequent may do, too. I just had some serious trouble last weekend and thus put it to a high frequency without checking if that's really needed. Best is to simply try different settings... All I know for now is that after I increased the frequency to this level, I never had problems again. Sometimes connection is immediately there, sometimes it feels like it takes 1/2 second, but I could connect each time with no exceptions (as far as I remember).

Of course, keep in mind: There might still be some other reason why this may not work. For instance, a few times I simply was too quick so that the server hadn't really registered with the MasterServer, yet, when I tried to connect with the client. The server or your network might also behave "oddly" causing the MasterServer to drop the connection (not sure what this might be, but it could be a possible cause). Finally, I had a few cases when a client couldn't connect, but once I had restarted the client, it suddenly worked (without re-registering the server).
Back to top
View user's profile Send private message Visit poster's website
Valendhar



Joined: 30 Sep 2007
Posts: 41
Location: Frankfurt, Germany

PostPosted: Mon Apr 21, 2008 8:38 pm    Post subject: Reply with quote
Hi Jashan,

I am currently developing a multiplayer game aswell, and i had similar problems.
Sometimes i started a server on one machine, and refreshed the list on my second machine which showed the created game. But after a few seconds the server disappeared from the List.

Another thing was, which is more frequent, i tested the game with a collegue of mine through the internet, and the web player files are hosted on my dedicated server.

When i start a server he can join the game without a problem, but when he creates a server and i want to join, i can click on the join button all the time but it just doesn't connect. I have based the program on the networking example. I Just don't know what this problem could be.

So can this be related to this problem aswell. I am still trying to figure it out.
Reading through the forum , i figured you seem to have a lot of experience with the unity networking, so maybe you have had some similar problems.

Any ideas or help would be appreciated.

Mike
Back to top
View user's profile Send private message Visit poster's website
EducaSoft



Joined: 09 Sep 2007
Posts: 576
Location: Wervik, Belgium

PostPosted: Mon Apr 21, 2008 8:43 pm    Post subject: Reply with quote
As far as I know, the webplayer starts the server automatically connects itself to itself.

So it makes no sense to connect to yourself if you are allready connected automatically I think

_________________
Why oh why don't I have time enough to do what I would really like to do ?
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Valendhar



Joined: 30 Sep 2007
Posts: 41
Location: Frankfurt, Germany

PostPosted: Mon Apr 21, 2008 8:53 pm    Post subject: Reply with quote
Hi,

I use the web player for easy testing purposes for multiplayer games.
Here is the a simple test i did.

http://www.valendhar.de/valendhardw.html

It just a simple testing application, to test some features and the GUI still has some problems with the text fields i still need to figure out, so don't mind it.

You can create a game with a name and description. Then it changes to a test scene , with just a simple chatting feature. Another player can then join the game through the available game list.

Testing it with a friend i could start a game and he could join. But i couldn't join his created game.

And sometimes it happened that a create game vanished from the list. So i thought that it may have something to do with the master server problems discussed in this thread.

Any help would be appreciated.

Mike
Back to top
View user's profile Send private message Visit poster's website
EducaSoft



Joined: 09 Sep 2007
Posts: 576
Location: Wervik, Belgium

PostPosted: Mon Apr 21, 2008 8:59 pm    Post subject: Reply with quote
just tried with 2 PCs and they can nicely connect and chat here
_________________
Why oh why don't I have time enough to do what I would really like to do ?
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Valendhar



Joined: 30 Sep 2007
Posts: 41
Location: Frankfurt, Germany

PostPosted: Mon Apr 21, 2008 9:06 pm    Post subject: Reply with quote
Hi EducaSoft,

thanks for your help. That is really funny. I tried it at home, using my iMac and MacBook yesterday and i could connect from both sides, but not all the time. And then when i tried it with a friend through the internet, we had those problems that i could not connect to his game.

That's really weird. Well, thanks anyways. I probably will see in further development stages if this will occur again.

I just thought that maybe the MasterServer could be the reason in some way.

thanks
Mike
Back to top
View user's profile Send private message Visit poster's website
jashan



Joined: 09 Mar 2007
Posts: 1546
Location: Munich, Germany

PostPosted: Mon Apr 21, 2008 9:12 pm    Post subject: Reply with quote
Hi Mike,

Just one quick answer, because I'm on the way to my bed Wink

Dharcon17 wrote:
Testing it with a friend i could start a game and he could join. But i couldn't join his created game.


That might be because NAT-punchthrough fails for your friend. A lot can be done with NAT-punchthrough, but sometimes it fails. You can still connect to a server when NAT-punchthrough would fail for you - but you can't host a server in that case (actually, it has to do with both, I think).

Your friend being able to join on your server, but you not being able to join on his server looks like a case of that. I think there's a couple of variables and possibilities, which are nicely documented in the networking manuals (don't have that stuff at the top of my head, though, so please excuse it I'm not being very accurate here Wink ).

The other problems you mentioned sound a lot like the master-server issue we had talked about, so I think there's two problems: One with NAT-punchthrough (it simply isn't possible in certain cases - one case being you not being able to connect to your friend's server), and the other with the master server. The former is probably something that you should handle from your game (I think there are checks to prevent people who can't create a server accessible to all from creating one, or there might be checks to hide those "servers" from the host list), the latter, you can workaround with re-registering frequently.

Sunny regards,
Jashan
Back to top
View user's profile Send private message Visit poster's website
Valendhar



Joined: 30 Sep 2007
Posts: 41
Location: Frankfurt, Germany

PostPosted: Mon Apr 21, 2008 9:18 pm    Post subject: Reply with quote
Hi Jashan,

thanks for your answer. But it seems that my friend had NAT punchthrough capabilities as well. That's why it seems weird. I can check again tomorrow.

The thing with the bed is actually what i need to do aswell now (getting up early for work)

But at least there are some good hints i can look into. But if that is the case with the NAT , then the whole idea of my game can be in danger.

Thanks again
Mike
Back to top
View user's profile Send private message Visit poster's website
robur



Joined: 13 Feb 2008
Posts: 346
Location: North Idaho

PostPosted: Thu Sep 11, 2008 3:06 am    Post subject: Reply with quote
I have been suffering from what appears to be this exact same problem in Mars Explorer, and it looks like it is getting worse by the day.

I just published the latest version of my game with a coroutine to reregister game servers every 4 seconds, and I am still experiencing "list server flickering" so bad that it is a pain trying to connect to a specific server in my game.

This is a major issue. The list server is dying! Unity: should I reregister my game every second - (or maybe even more frequently) - or is there some better way?

I was really hoping for this issue to resolve itself with the release of "the next version of Unity", but it looks like it didn't. What should I do?

_________________
Aubrey Falconer ~ of ATI Design
Mars Explorer FTW!
Back to top
View user's profile Send private message Visit poster's website
larus
Unity Networking Developer


Joined: 12 Oct 2007
Posts: 167

PostPosted: Thu Sep 11, 2008 8:44 am    Post subject: Reply with quote
Yes, the disappearing host problem wasn't solved when the new Unity version was released. It appears the problems gets more apparent when as the server gets more traffic. At first, during testing, it appeared it was fixed, but it wasn't.

We are looking into this problem again, I'll keep you posted.
Back to top
View user's profile Send private message Send e-mail
jashan



Joined: 09 Mar 2007
Posts: 1546
Location: Munich, Germany

PostPosted: Thu Sep 11, 2008 9:40 am    Post subject: Reply with quote
Hi Larus,

thanks for the update on this one! So it might be a good idea to host one's own Masterserver? Since it seems to be a problem related to traffic, this should not happen if one just uses a dedicated Masterserver for a single game.

Sunny regards,
Jashan

_________________
RaMtiGA 1/3: Traces of Illumination --- Experience the Unexpected!

Jashan's Developer Blog
Back to top
View user's profile Send private message Visit poster's website
larus
Unity Networking Developer


Joined: 12 Oct 2007
Posts: 167

PostPosted: Thu Sep 11, 2008 10:24 am    Post subject: Reply with quote
Yes, definitely. Hosting your own master server would probably eliminate or at least minimize this problem, until this is fixed for real.

It might be best to run it externally, especially if it would run with a private IP (NAT) and have machines using it locally as well as externally (with port forwarding of course). Access to a virtual server isn't that expensive these days I think.
Back to top
View user's profile Send private message Send e-mail
robur



Joined: 13 Feb 2008
Posts: 346
Location: North Idaho

PostPosted: Thu Sep 11, 2008 5:03 pm    Post subject: Reply with quote
Thanks Laurus!

I am glad to hear that the problem is being worked on, and wish you a speedy resolution to it!

I will see if I can get my own master server running in the mean time.

-Aubrey

_________________
Aubrey Falconer ~ of ATI Design
Mars Explorer FTW!
Back to top
View user's profile Send private message Visit poster's website
Post new topic   Reply to topic    Unity Community Index // Multiplayer Networking All times are GMT + 1 Hour
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum