Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

2D Multiplayer player is shaking

Discussion in 'Multiplayer' started by dmbrt, Jul 12, 2017.

  1. dmbrt

    dmbrt

    Joined:
    Jul 12, 2017
    Posts:
    1
    Hello everyone!

    I'm trying to build a small 2D Multiplayer Game and ran into a problem. The player that is not the local player is shaking pretty hard. I followed this Tutorial:


    I tried interpolating and set the network send rate to maximum but it still shakes. Also I used a different player prefab but it still didn't solve the problem, so it probably has nothing to do with my player prefab.

    Below you can see a video of what I mean. The green Cube is the local Player
    and the red (shaking) cube is the other.



    And here is a picture of my network settings for the player prefab:

    http://imgur.com/a/rsRIf

    Did anyone run into a similar problem and/or has an idea how to solve this? I would appreciate your help very much!
     
  2. TwoTen

    TwoTen

    Joined:
    May 25, 2016
    Posts:
    1,168
    Two things comes to my mind.
    1. You might be editing the remote players position on your end
    2. Something is messed up with your sync code.
    Please provide more details aand maybe code snippets.
     
  3. barnab_why

    barnab_why

    Joined:
    Sep 7, 2017
    Posts:
    1
    Assuming you are using a rigidbody, you need to sync the rigidbody rather than the transform.
    This will hopefully fix the shaking.