Guest LonestarDragon Posted April 5, 2005 Posted April 5, 2005 Okay, I apoligize ahead of time if I'm not able to explain this clearly enough. I trying to make a script for my Yu-Gi-Oh card game. I would like the script to wait until the pixel color at (x,y) is a certain color. example: hex 0xEE1D25 dec 15605029) before going on to the next step in the script. Here's what I have so far. WinActivate("Yu-Gi-Oh! PC") Do $var = PixelGetColor (x, y) Until $var = I've tried having it sleep instead but that doesn't always work out. As you can see I'm very new to this script making stuff and I've already hit a wall. Any insight into getting past this step would be greatly appreciated. Thanks, D.Y.
w0uter Posted April 5, 2005 Posted April 5, 2005 (edited) WinActivate("Yu-Gi-Oh! PC") While PixelGetColor (x, y) <> 15605029;wait till the pixel is the decimal color Sleep(100);wait a litle to ease the cpu Wend; check again ; rest of the code here Edited April 5, 2005 by w0uter My UDF's:;mem stuff_Mem;ftp stuff_FTP ( OLD );inet stuff_INetGetSource ( OLD )_INetGetImage _INetBrowse ( Collection )_EncodeUrl_NetStat_Google;random stuff_iPixelSearch_DiceRoll
Guest LonestarDragon Posted April 5, 2005 Posted April 5, 2005 Not sure what anyone of those Functions you gave me mean but it worked great. Thanks a bunch. D.Y.
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