UMG Buttons stop working

I have this UMG widget my_menu_bp. It has different buttons which work inside the Level BP.
So

http://a.pomf.se/ipadzb.jpg

  • If you press M it opens the menu,
    enables mouse control and then
    finally binds the event dispatchers
    from my_menu_bp. It works fine.

  • If I press the control tab it closes my_menu_bp and opens control_bp.

  • BUT if I’m inside control and I want to come back to my_menu all the
    buttons stop working. my_menu_bp
    opens and is added to viewport but nothing else happens.

This is the screenshot for my control_bp, as you can see is very simple. Onclicked button, it removes the control_bp and shows up my_menu_bp. And this is the exact moment when buttons stop working. After I press this button.

http://a.pomf.se/xrzcqb.jpg

What is causing this? Am I doing something wrong? Ive been stuck with this and I just cant find a solution.

If you need any additional screenshot or info, just ask me for it, thank you in advance.

For my reference, what are you casting to when you remove the widget in first pic?

Every widget. So if for example I Add to viewport widget1, widget2, widget3… I’m using that node for removing every single of them just with the M button.

So to dumb it down for me.

You have 3BP. When they are on screen, you can use a TAB at the top, you jump between them.

Is the scripting in your Character or Level?

Do any of the other Widget have to be live when yo are look at one. For example, Viewing, 2. Does 1 & 3 need to be attached to viewport?

This is the same widget issue you had the other day?

Its a different one. Last day I wanted to remove every widget from screen.
Now the issue is point by point :

  • Start Play level
  • Press M → my_menu widget appears → selecting materials from here works fine.
  • Change to controls control_bp (2nd pic), it changes fine.
  • Going back from control_bp to my_menu starts the problem. I cant select materials anymore. Buttons are not responding.

The scripting is inside Level blueprint.

If I’m inside control blueprint, the other widgets are disabled. Theres only one widget at a . For example (2nd pic) :

  • Click button → Removes current widget from parent → Creates the new one.

Have you tried to remove after casting to second widget?

Still not sure why you are cast everytime, why not set reference on begin play like you had the other day.

But I dont want to remove them, I want to enable my event dispatchers when I press the button Select Materials from inside the Controls widget. They only work when I first press M, then they stop working.

http://a.pomf.se/rqkvns.jpg

I was thinking like this.

So you when you go from Control widget, back to Menu reference, it is not referencing it properly as said on the forum post. Set your references up properly.

This is my event begin play, all my widget referenced

Just a quick question, that Variable you are setting from the Widget : menu , which is the correct way to put it inside your current widget?

Inside widget’s event graph

  • Add variable
  • In variable type select my_menu variable
  • Name it the same way as the one from Event Begin Play

http://a.pomf.se/crkkkh.jpg

And then, finally, replace all the variables I had with this new one in both widgets_bp and level_bp ?

Sorry for all the words, but I want to tie up this.

Not on click, reference it on creation of widget or begin play.

Do not set it as the same variable, have: control - control, have: menu - menu.

Do no use the same reference for different widgets. it will not go well at all from experience.

If its not much to ask, could you give me an example on how those nodes are created?
I’ll try to explain it in another image.

http://a.pomf.se/pwjmly.jpg

Im afraid Im doing this wrong all over again, I tried with several variables and configurations and it isnt working :frowning:

Cast to your First BP

Call that reference.

Give me a few mins, see what I can come up with.

Casting to level bp, is unknown to me. for such a small action, I would put in Player.

Easy to reference, cast and add to.

Thank you again,
I tried making everything inside my player bp but I couldnt do it specially for not being able to get static meshes for persistant level.

So just for clarify, the correct way would be Casting to my_menu bp from my widget’s bp? I’ll try that way and see if it works.
For the moment everything is still the same. :frowning:

In your world BP, cast yo your player, and pass details that way, instead of player casting to world bp.

To sum up, have every widget set as a reference at event begin and call those references.

Example about cast to widgets.

I had 1 widget that fired a staff member. I had a different widget for each staff type.

If i had looked at one widget and fired number 3, then went to next widget and fired number 2, it would fire number 3, because that is where the first reference was set.

If you cast to a widget and reference that widget, then delete and make a widget of the same name and pulled it back in, the reference will not reference the widget until I deleted the reference, and replaced all references.

Pain