Description

User reports:

I've noticed a bug with PlayMontageAndWait

 

There are 4 possible triggers when a Montage completes:

  • OnCompleted
  • OnBlendOut
  • OnInterrupted
  • OnCancelled

 

Once OnBlendout has been triggered - then if the montage gets interrupted, no pins will trigger - there will be no OnInterrupted, and no OnCompleted, it just silently stops the montage.

 

We have a number of abilities that end as a result of a montage completing, which means our designers will hook up OnCompleted and OnInterrupted to EndAbility. This will mean that very occasionally, a montage can get interrupted in the tiny time window between starting to blend out, and completing - the ability will fail to end - and we have a zombie ability that just sits there - blocking other abilities, and refusing to restart

 

I appreciate the fix is relatively simple in this trivial case - typically I attach a WaitDelay to the OnBlendOut pin, and then connect that to End Ability

 

In other cases where the ability has on- going logic, and potentially further montages, a bit more logic is required - usually a local variable connected to OnCompleted so that after the Waitdelay, I can check if OnCompleted triggered, and if not - connect as appropriate

 

So whilst the solution is simple in each case - I have to remind designers to do it - and overall: this feels a like a bug

Steps to Reproduce
  • Open Lyra
  • Open Lyra/Content/Characters/Heroes/Mannequin/Animations/Actions/AM_MF_Emote_FingerGuns.uasset.  Set the BlendOut time to 4.0 to give you a lot of time during BlendOut.
  • Open Lyra/Plugins/GameFeatures/ShooterCore/Content/Game/Emote/GA_Emote.uasset and hook up a bunch of print nodes on all of the possible output nodes of the PlayMontageAndWait task (including Blend Out and Complete in particular).
  • Now play the game, hit B to emote the finger guns.  Right after it starts emoting, walk forward.  Notice you'll get an OnComplete.  Now try again but wait for the OnBlendOut to start before you walk forward.  Notice how no other outputs fire during the OnBlendOut phase... but if you just sit there, both OnBlendOut and OnComplete will fire, indicating a bug.

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-183351 in the post.

0
Login to Vote

Fixed
Fix Commit25328943
Main Commit25328943
CreatedApr 14, 2023
ResolvedMay 4, 2023
UpdatedMay 12, 2023