On_input: position is inaccurate until mouse movement (Issue-4556) (SOLVED)

#1

Hello,

As I was developing a simple virtual stick widget, I noticed that sometimes when just starting up the app, the position would be wrong. After trying to zero in on the issue, I found that the values in action.x, action.y, action.screen_x and action.screen_y do not update until mouse movement occurs. This means that if the cursor starts within the window of the app and then mouse down occurs (without moving the cursor first), the position reported via on_input is inaccurate. In my case, it is consistently inaccurate, I suspect somehow related to my window dimensions (screen_x = 4, screen_y = 751).

I’m running via the default target on Mac OS. Not sure whether this would be an issue for other platforms.

0 Likes

#2

Doesn’t appear to be an issue on iOS simulator - presumably bcz there’s no such thing as a cursor or mouse move :slight_smile:

0 Likes

#3

Thanks. Created Issue-4556. This will likely get fixed in the next version.

1 Like

#4

Solved in 1.2.164

0 Likes