Jump to content

Making a Pixel Checksum True or false..


Regency
 Share

Recommended Posts

  • Moderators

PixelSearch(603,200,655,215,9175040,"",2)

how would i make a script make a Msg box IF this is true, and then if it is not have it repeat a groupe of lines in the script.

How would i tell if it was true or false...

Wrap IsArray() around PixelSearch() then do = 1, it will return true or false:
MsgBox(0,0,IsArray(PixelSearch(603,200,655,215,9175040,"",2)) = 1)

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

Wrap IsArray() around PixelSearch() then do = 1, it will return true or false:

MsgBox(0,0,IsArray(PixelSearch(603,200,655,215,9175040,"",2)) = 1)
#include <IE.au3> 
$oIE=_IECreate("http://www.themafianetwork.net/jail.aspx?")
_IELoadWait($oIE)
WinSetState("TheMafiaNetwork - National Jail - Microsoft Internet Explorer", "", @SW_MAXIMIZE)
WinSetState("TheMafiaNetwork - National Jail - Microsoft Internet Explorer", "", @SW_MINIMIZE)
  For $var = 0 To 100 Step 1
   _IELoadWait($oIE)
  _IELinkClickByText ($oIE, "Break")
  _IELoadWait($oIE)
  _IENavigate($oIE,"http://www.themafianetwork.net/jail.aspx?", 1)
Next
If MsgBox(0,0,IsArray(PixelSearch(603,200,655,215,9175040,"",2)) = 1)Then Exit
    If MsgBox(0,0,IsArray(PixelSearch(603,200,655,215,9175040,"",2)) = 0) Then

This is what I have. I dont know how to make it repeat the whole For Expression if the pixel search comes back false..

Anyones help?

Link to comment
Share on other sites

  • Moderators

Search the term loop...

Example:

While IsArray(PixelSearch(......info....)) = 0
    Sleep(10);CPU rest
    ;Stuff to perform while the PixelColor is not found
WEnd
Edited by SmOke_N

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

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