LunarX Posted February 22, 2010 Posted February 22, 2010 I don't know what it means. I been trying to ask but never find. I search everywhere and couldn't find anything similar to this. I don't anything about autoit scripts. So please help me =(. expandcollapse popup;Plays Dungeon! Func Start() AutoItSetOption ( "SendKeyDelay", 15 ) WinActivate("GranChase Season2 vbp0") $pixDet = PixelGetColor(243, 44) If $pixDet <> 16772217 Then Call("PE") Send ("{Enter}") Sleep (1000) Send ("{ESC}") Sleep (300) MouseClick ( "Left", 669, 542, 1, 1 ) Sleep(10000) Else Do Call("PE") For $i = 20 to 1 Step -1 Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Next $pixDet = PixelGetColor(243, 44) Until $pixDet <> 16764537 EndIf EndFunc
dani Posted February 22, 2010 Posted February 22, 2010 (edited) Well it means there apparently is a Do statement followed by some other expressions but not ended with an Until <boolean> statement. However, I don't see that error in the code you posted so I am not sure why you would get this error. You are 100% sure it gives that error on this piece of code? I can't verify as this is only a snippet and lots of code is missing Edited February 22, 2010 by d4ni
LunarX Posted February 22, 2010 Author Posted February 22, 2010 eh heres the whole code o-o expandcollapse popup;Enter Information Here: $login = "ID" $pass = "Pass" $rp = "fneaf" ;Set Directories $gc = "C:\Program Files (x86)\GrandChase Unlimited\Grand Chase.exe" ;PROGRAM STARTS BELOW :::::::::::::::::::::::::::::::::::::::::::::::::::::::::: SetPrivilege("SeDebugPrivilege", 1) AutoItSetOption ( "MouseCoordMode", 2 ) AutoItSetOption ( "PixelCoordMode", 2 ) AutoItSetOption ( "WinTitleMatchMode", 3 ) AutoItSetOption ( "SendKeyDownDelay", 70) HotKeySet("{F10}", "Terminate") Call ("Main") Func Main() While 1 ToolTip("F10 will Exit..." & @CRLF) Call ("Decision") Sleep(1000) WEnd EndFunc Func Terminate() $exit = MsgBox ( 36, "Terminate Program", "Are you sure you want to exit? " ) If ($exit = 6) Then Exit Else Call ("Main") EndIf EndFunc Func Processes() WinActivate("GranChase Season2 vbp0") Call("PE") If ProcessExists ("main.exe") AND WinActive ("GranChase Season2 vbp0") Then Call ("Start") Else Call ("Login") EndIf EndFunc Func PE() If WinExists ("Bug Trap") Then Call ("Restart") EndIf EndFunc Func Restart() WinKill ("Bug Trap") ProcessClose ("GranChase Season2 vbp0") Sleep(2500) EndFunc Func Login() AutoItSetOption("SendKeyDelay", 20) Call("PE") If ProcessExists("GranChase Season2 vbp0") Then Call("Restart") Else Run($gc) Sleep (20000) WinActivate("GranChase Season2 vbp0") Sleep(1000) For $i = 30 to 1 Step -1 If WinActive("GranChase Season2 vbp0") Then MouseClick ( "Left", 425, 308, 1, 1 ) Sleep(500) Send($pass) MouseClick ( "Left", 540, 282, 1, 1 ) Sleep(1000) MouseClick ( "Left", 604, 146, 1, 1 ) MouseClick ( "Left", 604, 146, 1, 1 ) MouseClick ( "Left", 604, 146, 1, 1 ) ExitLoop Else Do $var = PixelGetColor (245,46) If $var = Dec(0xFFEC79) Then Call("DetermineRS") MouseClick ( "Left", 149, 44, 1, 1 ) Sleep (200) MouseClick ( "Left", 551, 212, 1, 1 ) Sleep (200) MouseClick ( "Left", 391, 169, 1, 1 ) Sleep (200) MouseClick ( "Left", 704, 320, 1, 1 ) Sleep (200) MouseClick ( "Left", 704, 320, 1, 1 ) Sleep (200) MouseClick ( "Left", 732, 364, 1, 1 ) Sleep (200) MouseClick ( "Left", 443, 346, 1, 1 ) Sleep (200) Send ($rp) Sleep (100) MouseClick ( "Left", 388, 384, 1, 1 Sleep (500) ContinueLoop EndIf EndFunc ;Plays Dungeon! Func Start() AutoItSetOption ( "SendKeyDelay", 15 ) WinActivate("GranChase Season2 vbp0") $pixDet = PixelGetColor(243, 44) If $pixDet <> 16772217 Then Call("PE") Send ("{Enter}") Sleep (1000) Send ("{ESC}") Sleep (300) MouseClick ( "Left", 669, 542, 1, 1 ) Sleep(10000) Else Do Call("PE") For $i = 20 to 1 Step -1 Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Next $pixDet = PixelGetColor(243, 44) Until $pixDet <> 16764537 EndIf EndFunc
JohnOne Posted February 22, 2010 Posted February 22, 2010 expandcollapse popupFunc Login() AutoItSetOption("SendKeyDelay", 20) Call("PE") If ProcessExists("GranChase Season2 vbp0") Then Call("Restart") Else Run($gc) Sleep (20000) WinActivate("GranChase Season2 vbp0") Sleep(1000) For $i = 30 to 1 Step -1 If WinActive("GranChase Season2 vbp0") Then MouseClick ( "Left", 425, 308, 1, 1 ) Sleep(500) Send($pass) MouseClick ( "Left", 540, 282, 1, 1 ) Sleep(1000) MouseClick ( "Left", 604, 146, 1, 1 ) MouseClick ( "Left", 604, 146, 1, 1 ) MouseClick ( "Left", 604, 146, 1, 1 ) ExitLoop Else Do $var = PixelGetColor (245,46) If $var = Dec(0xFFEC79) Then Call("DetermineRS") MouseClick ( "Left", 149, 44, 1, 1 ) Sleep (200) MouseClick ( "Left", 551, 212, 1, 1 ) Sleep (200) MouseClick ( "Left", 391, 169, 1, 1 ) Sleep (200) MouseClick ( "Left", 704, 320, 1, 1 ) Sleep (200) MouseClick ( "Left", 704, 320, 1, 1 ) Sleep (200) MouseClick ( "Left", 732, 364, 1, 1 ) Sleep (200) MouseClick ( "Left", 443, 346, 1, 1 ) Sleep (200) Send ($rp) Sleep (100) MouseClick ( "Left", 388, 384, 1, 1 Sleep (500) ContinueLoop ;Needs an Until here EndIf EndFunc AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans.
LunarX Posted February 22, 2010 Author Posted February 22, 2010 Now i get, EndFunc. For statement has no matching Next statement. expandcollapse popup;Enter Information Here: $login = "" $pass = "" $rp = "fneaf" ;Set Directories $gc = "C:\Program Files (x86)\GrandChase Unlimited\Grand Chase.exe" ;PROGRAM STARTS BELOW :::::::::::::::::::::::::::::::::::::::::::::::::::::::::: SetPrivilege("SeDebugPrivilege", 1) AutoItSetOption ( "MouseCoordMode", 2 ) AutoItSetOption ( "PixelCoordMode", 2 ) AutoItSetOption ( "WinTitleMatchMode", 3 ) AutoItSetOption ( "SendKeyDownDelay", 70) HotKeySet("{F10}", "Terminate") Call ("Main") Func Main() While 1 ToolTip("F10 will Exit..." & @CRLF) Call ("Decision") Sleep(1000) WEnd EndFunc Func Terminate() $exit = MsgBox ( 36, "Terminate Program", "Are you sure you want to exit? " ) If ($exit = 6) Then Exit Else Call ("Main") EndIf EndFunc Func Processes() WinActivate("GranChase Season2 vbp0") Call("PE") If ProcessExists ("main.exe") AND WinActive ("GranChase Season2 vbp0") Then Call ("Start") Else Call ("Login") EndIf EndFunc Func PE() If WinExists ("Bug Trap") Then Call ("Restart") EndIf EndFunc Func Restart() WinKill ("Bug Trap") ProcessClose ("GranChase Season2 vbp0") Sleep(2500) EndFunc Func Login() AutoItSetOption("SendKeyDelay", 20) Call("PE") If ProcessExists("GranChase Season2 vbp0") Then Call("Restart") Else Run($gc) Sleep (20000) WinActivate("GranChase Season2 vbp0") Sleep(1000) For $i = 30 to 1 Step -1 If WinActive("GranChase Season2 vbp0") Then MouseClick ( "Left", 425, 308, 1, 1 ) Sleep(500) Send($pass) MouseClick ( "Left", 540, 282, 1, 1 ) Sleep(1000) MouseClick ( "Left", 604, 146, 1, 1 ) MouseClick ( "Left", 604, 146, 1, 1 ) MouseClick ( "Left", 604, 146, 1, 1 ) ExitLoop Else Do For $i = 30 to 1 Step -1 Call("DetermineRS") MouseClick ( "Left", 149, 44, 1, 1 ) Sleep (200) MouseClick ( "Left", 551, 212, 1, 1 ) Sleep (200) MouseClick ( "Left", 391, 169, 1, 1 ) Sleep (200) MouseClick ( "Left", 704, 320, 1, 1 ) Sleep (200) MouseClick ( "Left", 704, 320, 1, 1 ) Sleep (200) MouseClick ( "Left", 732, 364, 1, 1 ) Sleep (200) MouseClick ( "Left", 443, 346, 1, 1 ) Sleep (200) Send ($rp) Sleep (100) MouseClick ( "Left", 388, 384, 1, 1 ) Sleep (500) Next $pixDet = PixelGetColor(243, 44) Until $pixDet <> 16772217 EndIf EndFunc ;Plays Dungeon! Func Start() AutoItSetOption ( "SendKeyDelay", 15 ) WinActivate("GranChase Season2 vbp0") $pixDet = PixelGetColor(243, 44) If $pixDet <> 16772217 Then Call("PE") MouseClick ( "Left", 669, 542, 1, 1 ) Send ("{Enter}") Sleep (1000) Send ("{ESC}") Sleep (300) MouseClick ( "Left", 669, 542, 1, 1 ) Sleep(10000) Else Do Call("PE") For $i = 20 to 1 Step -1 Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Send ("{Left}") Sleep (5000) Send ("{Down}") Sleep (5000) Next $pixDet = PixelGetColor(243, 44) Until $pixDet <> 16764537 EndIf EndFunc
JohnOne Posted February 22, 2010 Posted February 22, 2010 (edited) How in the world did you write this code. expandcollapse popupFunc Login() AutoItSetOption("SendKeyDelay", 20) Call("PE") If ProcessExists("GranChase Season2 vbp0") Then Call("Restart") Else Run($gc) Sleep (20000) WinActivate("GranChase Season2 vbp0") Sleep(1000) For $i = 30 to 1 Step -1 If WinActive("GranChase Season2 vbp0") Then MouseClick ( "Left", 425, 308, 1, 1 ) Sleep(500) Send($pass) MouseClick ( "Left", 540, 282, 1, 1 ) Sleep(1000) MouseClick ( "Left", 604, 146, 1, 1 ) MouseClick ( "Left", 604, 146, 1, 1 ) MouseClick ( "Left", 604, 146, 1, 1 ) ExitLoop Else Do $var = PixelGetColor (245,46) If $var = Dec(0xFFEC79) Then Call("DetermineRS") MouseClick ( "Left", 149, 44, 1, 1 ) Sleep (200) MouseClick ( "Left", 551, 212, 1, 1 ) Sleep (200) MouseClick ( "Left", 391, 169, 1, 1 ) Sleep (200) MouseClick ( "Left", 704, 320, 1, 1 ) Sleep (200) MouseClick ( "Left", 704, 320, 1, 1 ) Sleep (200) MouseClick ( "Left", 732, 364, 1, 1 ) Sleep (200) MouseClick ( "Left", 443, 346, 1, 1 ) Sleep (200) Send ($rp) Sleep (100) MouseClick ( "Left", 388, 384, 1, 1 Sleep (500) ContinueLoop Until here EndIf Next EndIf EndFunc Edited February 22, 2010 by JohnOne AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans.
LunarX Posted February 22, 2010 Author Posted February 22, 2010 everything work now but bot doesnt do anything
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