XNA 4.0: mouse location is not what it should be

Started by
1 comment, last by Knight52 12 years, 11 months ago
I'm making a game and suddenly ( I swear, suddenly) mouse's location went... off.

Normally, location of the mouse at top-left corner of the windows should be (0,0), but suddenly when I was coding something completely irrelevant to mouse, it's just got off. I don't know where to look. I tried to undo what I was coding but it doesn't work. Can you give me some ideas where to look?
Advertisement

I'm making a game and suddenly ( I swear, suddenly) mouse's location went... off.

Normally, location of the mouse at top-left corner of the windows should be (0,0), but suddenly when I was coding something completely irrelevant to mouse, it's just got off. I don't know where to look. I tried to undo what I was coding but it doesn't work. Can you give me some ideas where to look?


How do you know it's off? You really have to give some more specific details about what is happening.
Buttons.

When mouse is where that button should be highlighted, it isn't.

Here's image when Windows pointer was exactly at top-left corner of game's window. Cursor you see is in-game one. that two numbers at first button is the location of the mouse game detected.

MyFirstRPG2011-05-2621-29-23-65.jpg





EDIT : Never mind. I found where went wrong. I inherited a class with Game1. That created a conflict up.

This topic is closed to new replies.

Advertisement