Jump to content

PixelChecksum


Recommended Posts

hi i am haveing some trouble with the PixelChecksum if i try and the the code below i get a "error allocating memory"

Sleep(1500)
$checksum = PixelChecksum(778,778, 150,150)

; Wait for the region to change, the region is checked every 100ms to reduce CPU load
While $checksum = PixelChecksum(778,778, 150,150)
  Sleep(1500)
WEnd

MsgBox(0, "", "Something in the region has changed!")

but if i chance it to

Sleep(1500)
$checksum = PixelChecksum(0,0, 50,50)

; Wait for the region to change, the region is checked every 100ms to reduce CPU load
While $checksum = PixelChecksum(0,0, 50,50)
  Sleep(1500)
WEnd

MsgBox(0, "", "Something in the region has changed!")

I can't work this out how can changing the pixel cause this error?

Link to comment
Share on other sites

Try

Sleep(1500)
$checksum = PixelChecksum(150,150, 778,778)

; Wait for the region to change, the region is checked every 100ms to reduce CPU load
While $checksum = PixelChecksum(150,150, 778,778)
  Sleep(1500)
WEnd

MsgBox(0, "", "Something in the region has changed!")

I have reversed the co-ordinates.


Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

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...