Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

How to sync transform of character's bone(spine)?

Discussion in 'Multiplayer' started by BonyYousuf, Aug 12, 2016.

  1. BonyYousuf

    BonyYousuf

    Joined:
    Aug 22, 2013
    Posts:
    110
    Hi,
    I am making a third person shooter where player moves his spine for the aiming. I am using "NetworkTransformChild" to sync the rotation of the spine but it's not working. "NetworkTransformChild" works with any other child object but character's bone.

    Is there any way to sync rotation of player's spine so when other player is aiming others can see where they are aiming?

    Thanks
     
  2. PhilSA

    PhilSA

    Joined:
    Jul 11, 2013
    Posts:
    1,926
    I think that's what NetworkTransformChild is for (?) though I have never tried it.

    However, if I were you, I'd simply sync a Quaternion or a Vector3 in the player object representing the rotation of the spine, and then apply that rotation to the bone on each client locally.
     
  3. BonyYousuf

    BonyYousuf

    Joined:
    Aug 22, 2013
    Posts:
    110
    Hi,
    thanks for the tips. This was my idea too as last resort. But I was hoping if there was a default way to do this like other child game object.