craft000
craft000

Reputation: 41

In unity, I want to edit an animator while keeping the pose of another animator for reference, how can I do it?

I want to edit the animation of an animator while keeping the pose of another animator for reference, how can I do it?

Upvotes: 1

Views: 218

Answers (1)

Rafloka
Rafloka

Reputation: 366

Unfortunately, as far as I know (and tried), there is no way to have 2 instances of the animation window (even the floating one).

Option 1: If the target model has the same bones, copy the keyframes of one clip into the new empty clip and work from there.

Option 2: If you need a visual reference only and no "keyframe precision", you could try to work with [ExecuteInEditMode] in a script on your reference GameObject. There you could then adjust the current animation clip and frame with some public variables directly from the inspector and work on the new animation clip in a second GameObject. Like so:

void OnValidate() {
    Animator.speed = 0;
    Animator.Play("YourReferenceAnimation", 0, desiredFrame);
    Animator.Update(Time.deltaTime);
}

Edit: It seems, you don't even need [ExecuteInEditMode] for that case.

Upvotes: 0

Related Questions