I am trying to get the location of my mouse in 3D space using
PlayerController()->DeprojectMousePositionToWorld
but it always fails. I assume it’s because the dragged UMG widget has set the controller to UI focus instead of Game focus?
EDIT: I can get the mouse pos on-screen while dragging UMG’s, through the UMG itself, but not through the OwningPlayerController, it is also a valid controller.
EDIT2: Trying to get the mouse pos scaled with DPI works for one tick. I assume it’s the tick that is before the focus switch. (UI to Game)
The controller does not know what’s happening to the mouse during drag and drop. The drag operation does have all the data. So you can project into the world from that: