Jump to content

not working as intended or missing something?


Recommended Posts

$targetalive = PixelGetColor (74,176)

While $targetalive = 0x00E800

SendWithDelay(1100, '7456789')

WEnd

So its all gravy until the Hex color changes at the cordinates of the variable. To my understanding the loop should end once returned with a false expression right? However in the over all code the keys keep looping even after $target is no longer 0x00e800.

Edited by adrian1386
Link to comment
Share on other sites

So its all gravy until the Hex color changes at the cordinates of the variable. To my understanding the loop should end once returned with a false expression right? However in the over all code the keys keep looping even after $target is no longer 0x00e800.

While 1
     If PixelGetColor (74,176) = 0x00E800 then
          SendWithDelay(1100, '7456789')
     EndIf

WEnd

This should do it, I hope, lol.

INI TreeViewA bus station is where a bus stops, a train station is where a train stops. Onmy desk I have a work station...
Link to comment
Share on other sites

So its all gravy until the Hex color changes at the cordinates of the variable. To my understanding the loop should end once returned with a false expression right? However in the over all code the keys keep looping even after $target is no longer 0x00e800.

in your code you can not return false because you only get once -->>PixelGetColor (74,176)

Please add $targetalive inside loop , so that when $targetalive is changed it will exit

$targetalive = PixelGetColor (74,176)

While $targetalive = 0x00E800

$targetalive = PixelGetColor (74,176)
SendWithDelay(1100, '7456789')

WEnd

-----------------------------------------------------------BSECE, MCPAIM: juliusrmsYM: jivy_21@yahoo.comMSN: juliusLramos@hotmail.comMobile #: (Globe): +639167031989Web: http://www.trendmicro.com

Link to comment
Share on other sites

That worked :P Thanks.

Which one? I never knew you could do lines like - While $targetalive = 0x00E800, lol I always thought they had to be a simple indefinite loop. I hate being a noob
INI TreeViewA bus station is where a bus stops, a train station is where a train stops. Onmy desk I have a work station...
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...