DodgeThis Posted October 10, 2006 Share Posted October 10, 2006 Aim: To verify if the cursor has changed.I do know that a cursor change in normal Window mode can be easily verified. But in game i belive it different story.I want to get the cursor change to trigger some event / function.The cursor basically changes from a arrow (some well designed graphic arrow ) to glowing sword (basically when its on monsters).basic function needed would be:$var=get the mouse pos ( x , y)$ y= get mousepointer color ($var[0], $var[1])Now the problem comes here:I dont know what is considered as the exact location of a pointer. Meaning since i would be using one square pixel as color change of the cursor.Sure i could use the pixel search function but , the problem is cursor as "n" number of different colored shades making it impossible to limit it to a single color variation search.So i decided if i could find the exact pin point square pix which is considered as the cursor position in terms of x and y.Once i have exact x , y i can get color of that particular pixel say its FFFFFF For e.g.My second problem (my lack of knowlege) after i get $y = Some decimal value of the color$hex_y = Hex($y , 6) --> This gives hex value of the color say ACDHH (Just for random something)Now i want to compare the variable value of $hex_y = FFFFFFIF true mouse click ($var[0], $var[1]) --> Basically click on current location.Please help me with the syntax for comparing:IF $hex_y=="FFFFFF" THENexecute some FUNC This part is not correct syntax wise, comparing a variable equals to some hex valueAnyhelp appreciated Link to comment Share on other sites More sharing options...
DodgeThis Posted October 10, 2006 Author Share Posted October 10, 2006 Err..Did everyone Skip this one?? Ok i think i got one more trick to find that out..But if someone already knows an easy way please post. Thank y ou Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted October 10, 2006 Moderators Share Posted October 10, 2006 http://www.autoitscript.com/forum/index.ph...hlite=%2Bcursorhttp://www.autoitscript.com/forum/index.ph...lite=%2Bpointer Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
DodgeThis Posted October 10, 2006 Author Share Posted October 10, 2006 So much to learn so less time. Thank you. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now