Is this a bug or am I missing something. When I get mouse position and set mouse position, in play mode New Editor Window (PIE), the mouse cursor automatically keeps moving down, why? Have video.

For context, was trying to make a code to lock the mouse cursor in a small box for dead zone aiming. Thus why I need to use get mouse and set mouse position.

Here is my blueprint code in the player pawn

Google Drive 24 sec video of my issue:

You can make this code in a new blank project (I used UE 5.6). The code works in play mode Select Viewport, and play mode Standalone, but when I do play mode New Editor Window (PIE) then this bug appears.

Does anyone knows why?

hi @Hero_Tales , you should take account of view port scale when calculating mouse position….

1 Like

how would you integrate this node into my current set up?
Also what is the point of viewport scale?

Asking as tried mouse position divide by viewport scale; and instead of the mouse cursor auto move down it just gets stuck in the top left corner now.

so how about multiply ?

still locked to the top left of my viewport

I remember having an issue similar to this when making objective markers. I wrote this for the widget and it worked, but you may have to use the inverse of this or something for what you’re trying to do