//TODO //HACK //Disabling transform for non-root-motion animators public override void Init(JediumBehaviourSnapshot snapshot) { base.Init(snapshot); if (!HasRootMotion) { JediumTransformBehaviour trans = GetComponent <JediumTransformBehaviour>(); trans.AnimatorBased = true; } }
public override void Init(JediumBehaviourSnapshot snapshot) { base.Init(snapshot); _walkBeh = GetComponent <JediumCharacterAnimator>(); if (Test.Instance._clientId == _parent.OwnerId) { // JediumTransformBehaviour trans = GetComponent<JediumTransformBehaviour>(); // trans.AnimatorBased = true; } else { JediumTransformBehaviour trans = GetComponent <JediumTransformBehaviour>(); trans.AnimatorBased = true; Animator a = GetComponent <Animator>(); a.applyRootMotion = false; } _walkBeh.Init((Test.Instance._clientId == _parent.OwnerId)); }