how do I find out which ui element is under the cursor?
Hi @228Arseniy228 ,
I’m not sure if I’m fully understanding what you’re trying to do, but here’s something that might help.
When you use “Show Mouse Cursor” and “Set Input Mode UI Only”, switches the player’s input from controlling the character to controlling the 2D UI widgets on the screen. This lets you hover and click on buttons, menus, etc.
When you use “Show Mouse Cursor” (unchecked) and “Set Input Mode Game Only”, it does the opposite , hides the cursor and returns full control to the player character.
If what you want is to interact with a 3D UI (widgets in the world), you can use “Press Pointer Key” and “Release Pointer Key” from the Widget Interaction Component, which simulate mouse clicks in 3D space.
here’s a video that explains it in more detail
If none of these solutions work, could you please explain a bit more about what you’re trying to achieve?
Hope it helps!
hi. I want to open the inventory. hold down the slot with the left mouse button and move it
Okey i understand ,you will need to override the function On Drag Detected
or On Mouse Button Down
In this video, the process of creating a drag and swap item system is explained. I recommend watching the entire series, as it does a great job of breaking down how to build a complete inventory system, or you can use it as a reference for what you’ve already created.
This documentation can also help you better understand how the drag-and-drop system works in Unreal.
I think with this, you should be able to achieve what you were looking for.




