Jump to content

CUSOR ID'S


Recommended Posts

See MouseGetCursor() in the help file for more information. But basically the following numbers are the ID's

0 = UNKNOWN (this includes pointing and grabbing hand icons)

1 = APPSTARTING

2 = ARROW

3 = CROSS

4 = HELP

5 = IBEAM

6 = ICON

7 = NO

8 = SIZE

9 = SIZEALL

10 = SIZENESW

11 = SIZENS

12 = SIZENWSE

13 = SIZEWE

14 = UPARROW

15 = WAIT

"So man has sown the wind and reaped the world. Perhaps in the next few hours there will no remembrance of the past and no hope for the future that might have been." & _"All the works of man will be consumed in the great fire after which he was created." & _"And if there is a future for man, insensitive as he is, proud and defiant in his pursuit of power, let him resolve to live it lovingly, for he knows well how to do so." & _"Then he may say once more, 'Truly the light is sweet, and what a pleasant thing it is for the eyes to see the sun.'" - The Day the Earth Caught Fire

Link to comment
Share on other sites

Sorry, read the post to quickly and didn't realize you were talking exclusively about unknown cursor ID's.

There are no functions in autoit that can determine an unknown cursor ID. The only cursor ID's that aren't available would be the hand ones and i would simply suggest that you not use those. If you are using custom cursors you have made, the script will work. You simply have to set the appropriate cursor to the appropriate place in the mouse properties. The ID's should therefore work even on computers where the user has selected a custom pointer, or a custom hourglass, etc.

"So man has sown the wind and reaped the world. Perhaps in the next few hours there will no remembrance of the past and no hope for the future that might have been." & _"All the works of man will be consumed in the great fire after which he was created." & _"And if there is a future for man, insensitive as he is, proud and defiant in his pursuit of power, let him resolve to live it lovingly, for he knows well how to do so." & _"Then he may say once more, 'Truly the light is sweet, and what a pleasant thing it is for the eyes to see the sun.'" - The Day the Earth Caught Fire

Link to comment
Share on other sites

But, these are 2 cursors in a game...

how do i set those?

the only way i can think of doing this, is to use the pixle search, but it does not include the cursor in the search... if just takes everything that is behind the cursor... if there was a way to set it so it searched the cursor pixles too, then that would be amazing.

--redcrusher

Edited by redcrusher
Link to comment
Share on other sites

you can get the cursorid easily enough. from that there is a windows call that you can use to get the graphic data used by that cursor. you can peek at a few pixels in that to tell which cursor it is. unfortunately, i'm at work and my sample code is at home..

Link to comment
Share on other sites

you can get the cursorid easily enough. from that there is a windows call that you can use to get the graphic data used by that cursor. you can peek at a few pixels in that to tell which cursor it is. unfortunately, i'm at work and my sample code is at home..

Please if you could post that code i would love it!!!

thanks!!!

-redcrusher

Link to comment
Share on other sites

Hmm, well I can't paste the C++ copyrighted code here, but I can tell you what it's doing!

First call GetCursorInfo(&ci); to find the cursor.

Next call GetIconInfo(ci.hCursor, &ii); to get the handle to the icon for it.

Finally, create a DC, select the icon into the DC, and you can call GetPixel() on the DC to retrieve pixels values. From there you should be able to determine which is which!

Good luck!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...