Seagul Posted October 19, 2009 Share Posted October 19, 2009 expandcollapse popupIf $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) If $result = 1 Then ;still looting Sleep(1000) Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Else Call("Logic") EndIf Link to comment Share on other sites More sharing options...
Authenticity Posted October 19, 2009 Share Posted October 19, 2009 Can you explain how does the $result variable's value is changed? Right now if it's 1 it'll sleep 15 seconds, otherwise Logic function will be invoked once. If you want it to be this way but in any arbitrary depth you can use recursion with a counter, or a loop inside a loop. Link to comment Share on other sites More sharing options...
JRowe Posted October 19, 2009 Share Posted October 19, 2009 I'm assuming what you're doing here is testing whether you're still looting, waiting one second, testing again, and so on, until you're not looting anymore. Do Sleep(1000) ;Call your function $result = Logic() Until $result <> 1 That's the Do, Until version. You could also use While, Wend, and even a For, Next loop. [center]However, like ninjas, cyber warriors operate in silence.AutoIt Chat Engine (+Chatbot) , Link Grammar for AutoIt , Simple Speech RecognitionArtificial Neural Networks UDF , Bayesian Networks UDF , Pattern Matching UDFTransparent PNG GUI Elements , Au3Irrlicht 2Advanced Mouse Events MonitorGrammar Database GeneratorTransitions & Tweening UDFPoker Hand Evaluator[/center] Link to comment Share on other sites More sharing options...
Seagul Posted October 19, 2009 Author Share Posted October 19, 2009 well you are right jRowe I dropped idea of it comparing result now it compares the position of the loot $position = MouseMove($a1, $b1, 0) If @error Then $bootyfound = $bootyfound - 1 Call("Logic") Else Sleep(1000) EndIf Link to comment Share on other sites More sharing options...
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