Hey guys, complete noob here. I’m trying to set up a shop menu for my game in unreal engine (4.27). I have it all setup but for some reason when i go play the game and go into fullscreen window it moves all of my buttons to the left. Any help would be much apreciated.
Can you post a screenshot of what it looks like at runtime and possibly your widget blueprint?
ive actually figured out the current issue on the page but i have a seperate issue now if you wouldnt mind answering. Ive got it setup to where i press P to open the menu and am trying to close it with the same button. But it only works on two of my pages and doent on the others. Ive tried swapping the “Remove From Parent” with “Remove All Widgets” to no avail.
So i press P which brings up this tablet and when i Press P again it closes it. When i press the app icon in the red square. It opens up the shop.
When the shop opens it will close if i press P. But if press any of the buttons in the red rectangle it takes me to another page and thats where P stops closing the tablet and it wont work on any of those other pages either. The bluprints are the same on each of the pages as posted above.
It could be that the widget switched to isn’t getting focus. So the P command might not be registering on that widget. A debugging trick is to attach a ‘Print String’ node at the end of the event to verify if it is being called or not.
Are you using a system to keep track of which widgets are open? You could store a reference for the current widget when you open it in your player controller then set it to remove from parent when you press P. That way it will always exit no matter what widget is open.
A widget switching system for a complex UI like you have would work wonders as well. Setting up an Enum for every widget page you want to be able to switch to. Then add in logic to set references along those enums, removing previous widgets to prevent clutter and maintaining focus so commands and buttons always work. You can also use interfaces and event dispatchers for updates