Download

Basic Animations on Actors

Hi everyone,

I would to know the best way to trigger basic animation on objects by blueprint.

For example, the player can hit objects like a lever. This lever, after it is hit by the player, will bring down (it’s just a rotation) with a blueprint.
So, I would apply a rotation to the lever but the player must see the rotation movement, it is an animation.
It is not a position and directly, an other position, without animation.

What is the best way to create the animation of the lever, triggered by blueprint? With matinee, by blueprint operations, with a skeletalmesh or others?

Thank you for your answers.

I assume you would set up a time line for the lever object that controls the rotation.
The lever bp has a boolean variable that says on / or (or up / down or whatever) when your player activates it, you cast to the lever bp and toggle its boolean variable and then based on that you exectue the timeline either in play or in reverse - depending on the current state. - Thats at least how Id try to do it.

Thank you Adeptus for your answer.

If I understand, i must use Matinee? If I use Matinee, I must use a Level BP and not a Class BP?

Imagine, my lever opens/closes a door (so 2 animations, one for the lever and an other for the door).
Imagine now, my level contains a lot of lever-door couples. I can not create a Class BP with the lever and the door that I can reuse in my level but I must create a Level BP and a Matinee for each Lever-Door in the level?

Sorry,

I understood. A timeline is not necessarily associated with Matinee engine! :slight_smile:

I would suggest you to have a look at a node called “move component to”. Put in relative rotation value and time and you are set.