Mouse X and Y position changing without any mouse movement

0 favourites
  • 4 posts
From the Asset Store
Simplistic hyper-casual game with nature elements. Tap to switch between the 4 elements and reach a better score.
  • I'm having an issue where my mouse Y is going up and down 500 units and my mouse X is moving about 5 even while the actual cursor is stationary. It only happens while I am holding down right click which is how I move the camera ingame. Any help on why this is happening?

    Tagged:

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • No idea. But your event screenshot gives a very partial view of what’s happening. Can’t see all the behaviors used, or other events that may change the scroll.

    As is, it looks like it can be simplified to one event:

    Right mouse down: scroll to mouse.x, mouse.y

    Anyways my best guess is some of those other camera objects also have the scroll to behavior. When the scroll is changed the mouse position will change since it gives the position on the layout.

  • maybe if you remove the -cameracenter from the equation. make the camera follow the mouse but as it is it is still difficult to move the camera with just less, the ideal is to do this sum by quadrant and a variable that adds the current position of the camera

  • So I don't know for sure why it is happening. It was the actual Mouse.X Mouse.Y that was moving in the debug menu. What I think was happening was the cursor would teleport, move the camera, then teleport back before the camera technically moved so it was just in a loop of moving its own position back and forth based on the camera. To fix it I have a separate object with a fast-moving MoveTo behavior follow it around rather than setting its position.

    Also thanks for the replies, really helped me re-think the problem

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)