Search Unity

Third Party 3rd Person Controller + Fly Mode & Photon Unity Networking

Discussion in 'Multiplayer' started by lolwhatevr13, May 17, 2017.

  1. lolwhatevr13

    lolwhatevr13

    Joined:
    Jan 1, 2016
    Posts:
    3
    I'm currently working on an online game, and it's doing pretty well. My only issue right now is that I don't know how to sync the Controller scripts. (The game uses PUN's DemoWorker find game Scene, if this is necessary.
    I need to know how to sync the controller scripts.
     
  2. TwoTen

    TwoTen

    Joined:
    May 25, 2016
    Posts:
    1,168
    I'm assuming the movement is client authoritive by the way you describe it. A good way to start is for every player to send their position and rotation 20 times a second or something like that to the server, The server then sends it to the other clients where they can apply it.

    For more complexity look into Interpolation, Server Authoritive movement, Extrapolation and Movement Prediction