Search Unity

What's the difference between maxConnections = 0 and = -1?

Discussion in 'Multiplayer' started by nafonso, May 1, 2008.

  1. nafonso

    nafonso

    Joined:
    Aug 10, 2006
    Posts:
    377
    I can't figure this one out. By the docs it says that:
    Well, I understand the part of no new connections can be made, it makes me think that nobody will be able to connect. But the second part, what the hell does that mean?! Existing ones stay connected?! They don't get kicked out?!

    Also, the first part doesn't work. If I set to 0, other players can still connect!

    Now for the second part of the maxConnections definition:
    This, although kind of confusing, makes me think that it will only allow back a player that was already connected (e.g. lost connection and tried to join again).

    However, if I set maxConnections to -1, I get exactly the same behaviour that with 0! A player that wasn't connected will still connect. Is this because I'm testing it with two instances of Unity running in the same computer (he assumes that the new player was "already connected" and lets me connect again)? Is this a bug? Or am I simply misreading the whole documentation?

    Regards,
    Afonso
     
  2. AngryAnt

    AngryAnt

    Keyboard Operator

    Joined:
    Oct 25, 2005
    Posts:
    3,045
    Sounds very likely. Launch a webplayer and get a friend to verify this.