Sometimes, you may find it easier to add simple keyframe animations in Unity directly. You’ve experimented with
adding scripted animations in the Update function, but that’s much more suited to continuous action. As soon as you
want to do something where the speed of the animation slows down, speeds up, varies, or just slows to a stop, there’s
a lot of math involved.
A better solution may be to use Unity’s built-in Animation editor to create your own keyframe animations.
As an introduction, you will be using it to lift the key from under the rock. First, you must hide the rock while you are
setting up the key’s animation.