Looking for workarounds in animation blueprints

I’m mainly a Unity developer but chose UE4 for my current project for a few reasons. And I’m having problems with animation blueprints, I can’t find some features which are present in Unity but seem to be missing in Unreal:

  1. Transition to an animation from any state. In Unity there’s a special entry point called “Any state” from which I can add just a single transition. In Unreal it seems to me that I’ll need to add transitions from every state, so I really hope there’s a better way
  2. Triggers. They’re ideal for things like attack animations, but I can’t find anything similar in animation blueprint. As a temporary solution I just set a bool variable to true and after 0,1 seconds I set it back to false. But it seems too hacky and unreliable to me as I don’t trust the delay node
  1. would be a Montage.
    Look into it.

  2. never trust a delay node. (Different fps different delay too at times).
    What are you trying to trigger?

A jump? It’s done with animation state machines.

A one off montage? It’s done via code in the character blueprint.

All in all, the animation blueprint should only have variables and state machines. Absolutely no logic or any overly complicated stuff to get a state to trigger.

Example of a proper jump.
3 animations.
Jump start - the player pressed jump. The capsule goes up. The animation plays.

Jump loop. Static Frame of mid Jump. Plays endlessly.

Jump land. The character BP detects proximity to the ground, and at a specific distance sends the variable change to the animation BP so that it transitions to this state off the loop state.

Hope that helps.

1 Like

I’ll look into it. Does it blend with anim BP?

I’m trying to trigger attack animation, which can transition to combo follow-up attack. My initial logic was:

  1. Player hits attack button and activates attack trigger and animation transitions to attacking state
  2. In the end of the animation anim BP starts listening for the trigger again and transitions to combo state if the trigger was activated (or animation just transitions to normal state obviously)

I found out that transitions can call events and managed to create something similar to trigger: player hits the button, which sets isAttacking bool to true and the begining of currState->attacking transition calls an event, which sets isAttacking to false.
But it doesn’t seem to be reliable too since I can easily miss some transition events set up, which can lead to stuck state
Yeah, it’s easier with jumps, it’s set up like this in my case actually. But attacking is a bit different because it’s purely controlled by a player who can keep mashing the button and mess up variables

Yes montages blend.

For attack and combos you want a button press buffer so you can interpret and swap montage out as you go.

There’s plenty of discussions on here on how to do it properly.

The best way is montages.

The Ok but definitely not best approach is to swap blueprints out at runtime with every attack - this can work without hitches and can also provide a way to lock out abilities/combos via code rather easily.

The “no” way is to just put 300 attacks and logic to trigger them in the animation BP.
It can work, but you’ll go nutz trying to connect everything to everything.

Re the events:
From an animation those are called Norifies, and are indeed not reliable.
From the actual transition state where you write the rule, those are kinda still notifies, but they always fire (so far anyway).

I suggest avoiding them anyway because of future portability. Not really sure if or how they will keep being supported and always fire or not (and you’ll never find data on it), so its safer to just come up with a system that doesn’t rely on them at all.

1 Like

We swap out anim BP’s based on the context of the animations. If a player triggers a ladder then the animation BP switches to an animation BP that controls the player while they are on a ladder. As soon as the player exits the ladder the load back in the BP the controls the locomotion states

We also switch to a free run BP that allows the player to run around full body with out weapons

IN general though the animation BP needs assists from a lot of different directions, including from the map it’s self, as all animations have to function with some kind of context in which they are applied.