shea851 Posted October 14, 2007 Posted October 14, 2007 I want to call a function that checks for a pixel color indefinitly until it's not that color. How can I make a function "refresh" or go to the beginning of itself? Func checkCast() If (PixelGetColor($x, $y) = $color) Then Sleep(500) checkCast();can a function call itself inside itself? i dont think so? how do i do this part? Else Sleep(10) EndIf EndFunc
Paulie Posted October 14, 2007 Posted October 14, 2007 (edited) Do $i = CheckCast() Until $i = 1 Func checkCast() If (PixelGetColor($x, $y) = $color) Then Sleep(500); pixels are same color Return 0 Else Sleep(10);pixel is different color Return 1 EndIf EndFunc Edited October 14, 2007 by Paulie
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