Animations without layers problem
Hi I've been trying to trigger touch animations that blend into the idle animation.
I was able to create 2 layers of animation by separating the time at which the animation happens by following the guide.
The problem I'm having now is that when I touch to trigger secondary animation, my idle animation will reset to frame 0 and then the secondary animation starts. Is there a way to have the secondary animation play over the idle animation without it resetting the idle?
Example snap below.
https://drive.google.com/open?id=1_OVzfynKPJKHvi4V7XLPLOfZfnyVv6lD
The other issue I'm having is getting the animation to loop back to idle after the tapped animation finishes.
Currently the lens just stops after the tapped animation.
Hello Tom,
You can follow Animation without layer guide and use the custom script that is provided to have your animation to loop back idle after the tap animation.
Just make sure to download the Interactive Tap template file and replace both script with the provided scripts.
For the blending between the two state of the animation you need to setweight for your Animation mixer, the max value for the weight is 1. When you put 1 on the setweight your animation will play normally and if you want to blend with two state you have to lower the weight of your first animation from 1 to zero and for the second animation change your value from 0 to 1. In this way you can blend between your animations.
we use Lerp to linearly interpolates between two vectors.
I created a script which will let you too blend between two animation layers
Best,
Amir.
Hi Amir,
Thank you for your help.
I'm still having trouble implementing this and I've followed the Animation without layers guide but I'm still not getting the loop back to idle after the tap animation.
I've attached project folder so you can see what my setup looks like. I'm currently using the idle, tap and your blend script above all at once.
the idle animation is 0.00 - 9.00 and tap animation 9.00-12.00
https://drive.google.com/file/d/1uaPFkXn-GfP3deaQ6nRZ4HI3X1nAyZsa/view?usp=sharing
Hi Tom,
To loop your animation from tap to idle, please open the "TapAnim" script file in your project and change the line 80 from:
to this one:
Great thank you Amir that worked.