Newbie asks: Get MousePosition and also when Mouse click

Non-platform specific questions.

Newbie asks: Get MousePosition and also when Mouse click

Postby ggesterGamePro99 » Mon Apr 16, 2012 9:29 pm

Basically.

1How do you get the position of the mouse at any moment.

2And how do you set the position of the mouse at any moment?. Like if you want the computer to trick the user and move his mouse to parts where he doesn't want.

3. And How do you get the position of the mouse when clicked so that you find out if a player clicked the Start screen or Selection screen at specific buttons or specific text or if it's within a game that uses the mouse, to check if the user clicked some specific area or point or object within the screen.
ggesterGamePro99
 
Posts: 44
Joined: Mon Apr 16, 2012 1:53 am
Score: 0 Give a positive score

Re: Newbie asks: Get MousePosition and also when Mouse click

Postby phyzix5761 » Mon Apr 16, 2012 9:49 pm

1. xmouse and ymouse are built in variables that hold the x and y of the mouse at all times.

2. As far as I know you can't. :(

3. in the "mouse button down" event you can set two variables to hold the xmouse and ymouse.
phyzix5761
 
Posts: 261
Joined: Sun Feb 27, 2011 4:28 am
Score: 18 Give a positive score

Re: Newbie asks: Get MousePosition and also when Mouse click

Postby ggesterGamePro99 » Mon Apr 16, 2012 10:02 pm

phyzix5761 wrote:1. xmouse and ymouse are built in variables that hold the x and y of the mouse at all times.

2. As far as I know you can't. :(

3. in the "mouse button down" event you can set two variables to hold the xmouse and ymouse.



Thanks alot, awesome.
ggesterGamePro99
 
Posts: 44
Joined: Mon Apr 16, 2012 1:53 am
Score: 0 Give a positive score


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest

cron