Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice

Question Jump Sync over Network issues

Discussion in 'Multiplayer' started by MaazBaig, Sep 7, 2023.

  1. MaazBaig

    MaazBaig

    Joined:
    May 17, 2013
    Posts:
    38
    Hey guys, So i've always had an issue with this topic.

    Currently im testing this with NGO, but i've had same results in Photon PUN where the jump is "synced" with the fact that we're syncing the transform and animations, but of course those are lerping and smoothing out so that doesn't really translate well with Jumping because the Jumps are a bit Snappy and over network they end up looking a big sloppy and lerpy.

    What's the right way to sync jumps over network? Should i just fire RPC whenever they jump and try to do it locally?
     
  2. genxium

    genxium

    Joined:
    Jun 7, 2013
    Posts:
    14
    Interesting problem, by "a big sloppy and lerpy" I'd like blame that

    Jumping, or any other critical operations like attacking, cannot be predicted for real human participants.

    Moreover, the solution depends heavily on how realtime you want in your game, as well as tons of other factors like whether or not you can use UDP and whether or not you have an authoritative backend.

    Before bragging about the solution, I'd like to introduce what I've achieved in my demo


    What you see above is a recording via internet between a 4G user and a WiFi user, both Android phones. The sync of jumping doesn't look quite abrupt right? Here're what I did to solve this issue.
    Hope it helps