Search Unity

Can a one-time network event just... get lost sometimes? (Using Unity Networking)

Discussion in 'Multiplayer' started by J_P_, Oct 5, 2010.

  1. J_P_

    J_P_

    Joined:
    Jan 9, 2010
    Posts:
    1,027
    I'm trying to figure out if some of my network bugs are completely my fault or if perhaps Unity just isn't doing what I expect of it. My CTF code for example runs fine whenever I test it myself over LAN or on the same machine, but in real-world playtests over the internet, it has problems keeping everyone synced and I'm getting frustrated trying to get it working right 100% of the time -- it seems like something that should be relatively easy to do...

    When I write code telling the server to call a certain RPC on a client, I expect it to happen everytime -- but is this wrong to think so? If the server is temporarily hanging, this desync problem seems to have a much higher chance of happening -- does it not 'catch up'? How do people usually protect against this sort of thing?

    This CTF code is already server-authenticated, but do I also need to get the server to confirm the changes with the client actually happened? I'm imagining the server would keep bugging the client until it gets confirmation that things line up. Is this necessary...?

    I'm still using 2.6 if that matters.
     
  2. cerebrate

    cerebrate

    Joined:
    Jan 8, 2010
    Posts:
    261
    RPC's, are, as the reference manual says, always made sure to be received. Even if there's a hang somewhere, the sender is always going to make sure the message was received by the recipient.