UE 5.1 from GIthub:
I have a blueprint that owns a menu widget. A pause menu in this case. Simple.
My other widgets seem to be able to access the players info easily with casting and function calls. This new widget, that is created and owned by a BP (so I can add niagara particles) gets errors and is unable to call any information or even destroy itself, as far as I can tell.
Is there some settting or creation type that I need to go through to do this?
Previously I was adding a widget to the player, iirc, setting the game to pause, etc. Easy. Lots of tutorials on the subject.
Now that I am creating the BP, either as a child component or SpawnActor BP, the widget seems unable to cast the player controller as a TopDownController in my case.
What am I missing? I dont see anything in the Widget defaults or class settings that is different from my HUD widget, that can definitely get player info.
I got it. I had to Get Owning Player Pawn, cast that to the owning BP type, and call an event that the BP had. That BP can access the player controller and call player events and do whatever I want.
Now im trying to figure out how to return to the players camera, controls, etc… what a pain. But my menus will pop! I hope…
1 Like
I also ended up using the Get All Actors of class and getting my player that way. For no reason that I can see, the get player controller stopped working.