Mouse hides and shows when I don't want it to?(BP)

I have a problem where if I press any UI in one of my widgets the mouse cursor hides.


image
image

Anything in blue or outlined in blue hides when you press it. And the boxes with red outlines do not hide when you press them. The blue is part of a widget called HUD and the red boxes are a child to HUD but have a different widget class that is not derived from the HUD class. The problem is I have told them to do the opposite. I have looked this issue up but none of the solutions seemed to work for me.

I have an input event for pressing and releasing the red boxes but no input events for the other UI.

How to control whether the cursor is on or off absolutely?

And you don’t have a Show Mouse Cursor node anywhere else? Where is that node being called btw?

I don’t, I’ve checked and when I print whether it is shown or not every tick it says true and false when it should(how I intend it to). It just does the opposite and if I opposite the true/false it does the same thing.

I’ll try look into it when I have time.

Edit: Actually, to save me time recreating what you already have? Would you mind sending a minimal (not) working project by using the following link?

https://gdev.tv/projectupload

Please use File > Package Project > Zip Up Project within Unreal as this will ensure only required files are zipped up and things like the Binaries are excluded.

Just create a third person blueprint project and then use asset actions to migrate the HUD over and please make sure that project has the problem before packaging and sending.

1 Like

I have reduced it to only what is necessary for in to run. For some reason I can’t delete some empty folders so the folders to look at are clearly labeled.

I’m a little confused, the message you gave is the opposite of the OP?

The OP says clicking a widget hides the cursor, your message for the link says clicking outside of it.
Did I misread either?

The problem you gave in the link is solved by unchecking Hides Cursor During Capture.

1 Like

The problem changed a little for some reason because a quick fix stopped working. Thanks for a solution, but there is still one more problem. Holding click on the green icon the mouse cursor is still showing even thought I’m telling it not to. When you press “i” the inventory opens and shows mouse cursor but after that the “show mouse cursor” doesn’t do a thing, why and how do I fix this? Also what is “during capture” what is defined as capture?

Where are you telling it to not show? A quick look around, I can’t find any usage.

Not interacting with the UI. Game capture.

I am telling not to show when you press on an item slot.
Under “ItemSlots” widget, under comment “On Pressed” at the end of the chain.


This is where I tell it to hide. It does set mouse cursor to false, I did testing and it stays set to false for as long as you are holding down click on the item. But it isn’t hidden.
What am I missing?

It appears you need to set the cursor to none
image
And then back to default

Got the solution from here
UMG - How to get rid from the mouse cursor when giving focus? - Blueprint Visual Scripting - Unreal Engine Forums

Thank you that worked perfectly.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms