Blueprint Execution Debugger (Cast To)

I have noticed that the execution path in the blueprint debugger can be a little bit strange when doing casts.

I hadnt noticed this before the latest update (maybe because it didnt exist) but I can see the execution path look like it failed to Cast but then execute the next node in sequence.

This is one simple example but I have seen it in a few places, mostly always on overlap events.

Hey thunderbeans,

Does this always happen with the same Blueprints, or does it work sometimes and not others? Does it happen in a new project, or only your current project? Do you have any consistent steps to reproduce it, or a case that will always create this bug? Thanks!

Unfortunately not easy to reproduce. It seems to only be on one of my classes, which inherits from Character, I used for an NPC. It happens in any blueprint in that class but no other classes. It looks like its specific to just that class, and I think it may be something to do with upgrading to 4.7.2 as I didn’t notice it before.

I have tried to reproduce but to no avail I’m afraid. I guess I’ll just have to live with it or try recreating the class.

I’d be interested to hear if anyone else has the same problem at all though.

I don’t know if it helps at all, but in my character blueprint the little lines that highlight when execution runs through them only highlight for a split second instead of the nice fade out I usually see. Not sure if its related but both these issues are very irritating.

Video of it here - YouTube

From what I can tell after a bit more testing, these symptoms are related. However it only seems to be functions relating to my main character actor. Any functions that are called from it (including trying to cast it) will cause strange execution path patterns like the ones I have seen.

The MyCharacter blueprint I’m using was taken straight from the top down example project in version 4.6 and apart from adding a few functions, variables (including references to UMG widgets) I haven’t really done that much to it.

Looks like I’ll just have to recreate the whole class :frowning:

Final thoughts on this, it seems to be UMG related.

The first thing MyCharacter blueprint does on begin play is create an array of struct class, then create and add the HUD and then create and add a menu. I believe that it is having widgets with lots of sub widgets added to the viewport (maybe all at once) seems to break the visual debugger for the blueprint it was created on.

Before you do that, I’d like to run this by the devs to see if they know what might have caused the issue. You’re probably correct that it happened in the conversion to 4.7. Would it be possible to get a copy of your project with these bugs? If you can upload it somewhere and get me a download link, that would be great. Otherwise, if the character and NPC Blueprints are relatively self contained, you might be able to simply zip and attach those here and we can try them in a new project.

I just got it, you can take it down if you need to. Thanks!

Heres a download link for a copy of the project. Its pretty butchered as I had already rewritten a lot of it to work around this issue.

I was able to reproduce the symptoms by putting together some old bits of code though. You could probably get rid of everything except the character and the UI widgets I was playing around with if needed.

If you check out the character event graph you should be able to see it. I believe it must have something to do with the creation of the UMG widgets.

I originally had like 3 or 4 widgets that had canvas panels in for my menus (basic HUD, inventory, skill menu, etc), so to work around I just put them all in the one HUD widget.

Please let me know when you have got a copy. Thanks :slight_smile:

When I run MyCharacter, the Event Graph doesn’t seem to animate any of the node wires. This seems true for the NPC as well. That seems somewhat different than what you were seeing. If you open the same version of the project you gave me, is that what’s happening for you now as well?

Mine currently does the same, and I was able to create this behaviour by adding multiple sequence nodes all adding new widgets (see the MyCharacter event graph).

My best suggestion is to look at the MyCharacter event graph and try removing some of those sequence nodes to add less widgets, it seemed to alter the behaviour.

To be honest I kept seeing different behaviour (no nodes animated, only partially animated, only some nodes in sequence animated, only animated when focused on the scene) and it is very inconsistent to try and reproduce.

Unfortunately I can’t really give a solid set of steps as its so inconsistent.

I have another issue with UMG, I’m not sure whether I should raise another question for it as it might be related to this.

My editor keeps not saving this change I make.

However if I change something else like the execution path or something that saves. Is it maybe something to do with interfaces and struct parameters? I really am lost with this one.

Is this a known issue? Is there a work around? Its getting rather hard to work on this project :frowning:

I’m not certain I recognize it, but it’s almost definitely unrelated to the bug with the node wires not animating. Would you mind opening a new post in Bug Reports for that? I’ll make sure we get someone to look into it.

Hi thunderbeans,

I was able to reproduce this in your project, and I have entered a bug report for it with your project attached (UE-11772) so the developers can take a look. I’ll let you know as soon as I see any update. Thanks for your report!

New question raised, thanks for getting back to me.

Hey Ben, is there a way to search if a specific bug was addressed? I’m pretty sure I’m having the same issue - my UMG can’t cast to my player character - it’s getting the “execution path doesn’t end with a return node” error. I tried storing the variables in my game mode but i can’t seem to cast to there either.

Was there any sort of workaround? I’m in 4.8

update: just started working. no idea what i did differently - but i went through double checking that everything was connected and it’s not giving that same error, so… yeah! TY! :slight_smile:

Unfortunately, I couldn’t work around these UMG bugs and had to stop using UE4 all together. Hopefully when its a bit more stable I will be able to come back to it.