Download

Set an "area" to play a character's animation

I’m trying to get my character to jump over a fence with a special animation,
now I want to know, how I would to that.

uu2x6Yj.png

The yellow box would be like some volume which let’s the character perform
that animation if a button is pressed. How would I make that? How could I make
an area where if you press a button, the character performs that animation, and
tries to orientate to the volume?

Any tips? :frowning:

Add a trigger volume in the level editor. Then in the blueprint add an OnOverlap event leading to a ‘key pressed event’ (right click and type ‘f key’ for example to find the type of node I’m talking about). From the ‘pressed’ output you can set some kind of flag that is replicated in your animation blueprint and when true will play the animation.

In summary:
Trigger Volume
Key Pressed event
Boolean Flag -> Animation Blueprint Boolean Flag