Search Unity

Resolved Rigged Anims synch

Discussion in 'Netcode for GameObjects' started by liambilly, Feb 15, 2023.

  1. liambilly

    liambilly

    Joined:
    May 13, 2022
    Posts:
    154
    How can one go about synching rigged animations accross the network
     
  2. RikuTheFuffs-U

    RikuTheFuffs-U

    Unity Technologies

    Joined:
    Feb 20, 2020
    Posts:
    440
    Hi @liambilly , you can use a NetworkAnimator (if your game is Server-authoritative) or a ClientNetworkAnimator (if your game is Client-authoritative)
     
  3. liambilly

    liambilly

    Joined:
    May 13, 2022
    Posts:
    154
    im using the clientnetworkanimator, all the other animations are synchronized except the rigged ones

    to expand more on this i rigged my character in the idle animation to hold different objects different ways,i recorded and binded the positions of the bones of the character to an diffrent animations; and i update the holding animations at runtime with an animatoroveride, but these riggied animations only play locally to the other clients it shows the character in his idle state,

    these animations play from a different layer also

    tthat aside even when using multi aim constraint to look at target, it doesnt synch
     
    Last edited: Feb 16, 2023
  4. mishakozlov74

    mishakozlov74

    Joined:
    Aug 8, 2018
    Posts:
    143
    I believe you have to sync your rigs (position and rotation) too, Animator syncs only animations.
    It doesn't sync it bone to bone, it just runs the same animations.
     
  5. liambilly

    liambilly

    Joined:
    May 13, 2022
    Posts:
    154
    [SOLVED]i found a solution, from an idea i got from code monkey, apart from attaching networktransform to the ik targets also you need to change the rig layer weights with a networkvariable
     
    Last edited: Feb 17, 2023
    mishakozlov74 likes this.