Using Timeline Animations in Unreal Engine 4

Check out our previous post about using Timeline Animations in Unreal Engine 4. We have discussed about the basic structure of blueprint Timelines in that post.  Now we will create a simple example animation using Timeline Animations in Unreal Engine 4.

In this example we will be creating a simple bridge link which will get activated on a trigger.

  1. First of all we need to add a Cube static mesh and adjust its scale so that it looks like a bridge that we want to use for connecting two floors. In details panel , dont forget to set its mobility to “Movable”.




    Using Timeline Animations in Unreal Engine 4
    Using Timeline Animations in Unreal Engine 4

     

  2. Place this mesh below the first floor. It will be the initial position of your bridge mesh. In your level blueprint , use Event beginplay method to store this location into a variable.

    Using Timeline Animations in Unreal Engine 4
    Using Timeline Animations in Unreal Engine 4
  3. Now add a trigger box on first floor which will make our animation to play.

    Using Timeline Animations in Unreal Engine 4
    Using Timeline Animations in Unreal Engine 4
  4. On Overlap event of this trigger, we will check that whether the overlapping actor is our player, if yes then we will play Timeline animation to change the location of bridge from initial position to some desired final position.
    Using Timeline Animations in Unreal Engine 4
    Using Timeline Animations in Unreal Engine 4

     

  5. We are performing a “LERP” operation on X axis movement of bridge mesh. It is moving 400 units on X axis in certain time as defined in our Timeline node. Our Timeline node have defined a float variable, whose value is changing from 0 to 1 in one second, and this variable is used in alpha input of Lerp node. (Alpha value 1 denotes that transition from value A to value B is complete). So our mesh will change its position from its initial position to final position with a smooth transition effect. Timeline settings are as follows :
    Using Timeline Animations in Unreal Engine 4
    Using Timeline Animations in Unreal Engine 4

    The keyframes are added using shortcut “SHIFT + LEFT MOUSE KEY” on graph.

    Thats it. Now you have just created a simple Timeline animation using blueprints in Unreal Engine 4.

    If you are having any doubts in mind, feel free to ask in comments.

    Happy Game Making !! 🙂

Social sharing
Share on FacebookTweet about this on TwitterShare on Google+Share on LinkedInPin on PinterestShare on RedditShare on TumblrEmail this to someone

One thought on “Using Timeline Animations in Unreal Engine 4”

Leave a Reply

Your email address will not be published. Required fields are marked *