How do I get the mouse input direction from the center of the screen to trigger an event from the released position of the mouse?

i tried to set it on the event tick of one of my widgets for the arrow direction and now is shows the mouse cursor without me asking it to and it still gets stuck in ui mode