Search Unity

Multiplayer rotation

Discussion in 'Multiplayer' started by wroblak, Jul 18, 2017.

  1. wroblak

    wroblak

    Joined:
    Mar 16, 2016
    Posts:
    1
    Hello guys

    I have a problem with rotation in my multiplayer game. I build the game and launch it, after that i launch the game in editor. When I'm moving player in build game everything looks fine, rotation and position in editor looks great, but when i'm starting to move player in editor then rotation on client is incorrect. I'm using Network transform for that. Unity version is 2017.1. I had also older versions - the same problem there. Will be very appreciate for any help.

    It seems there is nothing wrong with editor, the problem is with first client (on witch I click LAN host(H)). When I'm playing on this client problem with rotation occurs. It looks like player makes some additional rotation/position changing.
     
    Last edited: Jul 18, 2017
  2. xVergilx

    xVergilx

    Joined:
    Dec 22, 2014
    Posts:
    3,296
    Make sure you're not modifying your rotation multiple times:
    Since the code that is usually executed on the clients will probably be executed on your server too, which in a result leads to that behavior. (As far as I understood the problem is on a host, which is both a server and a client)

    Without the code it's impossible to say what you're doing wrong.
     
    TwoTen likes this.