Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <ButtonConstants.au3>
- #include <EditConstants.au3>
- #include <GUIConstantsEx.au3>
- #include <StaticConstants.au3>
- #include <WindowsConstants.au3>
- #include <ScreenCapture.au3>
- #include <Date.au3>
- $RND = Random(1, 2, 1)
- $name = random(1,1000)
- $i = 1
- $l = 1
- $x = 1
- dim $spelldmg
- dim $spellbuff
- dim $spelldef
- dim $pw
- HotKeySet("l", "Stop")
- $z4x = GUICreate("Paint", 151, 263, 510, 422)
- GUISetFont(8, 800, 0, "MS Sans Serif")
- GUISetBkColor(0xFFFFFF)
- $Button1 = GUICtrlCreateButton("Start", 32, 232, 75, 25, $WS_BORDER)
- GUICtrlSetBkColor(-1, 0xF4F7FC)
- $Label1 = GUICtrlCreateLabel("sTylBot 0.1", 0, 0, 149, 17)
- $Label2 = GUICtrlCreateLabel("1280*1024Engl. Client", 0, 24, 149, 17)
- $Label3 = GUICtrlCreateLabel("Damage Spell:", 0, 48, 111, 30, $WS_BORDER)
- GUICtrlSetFont(-1, 12, 800, 0, "Palatino Linotype")
- $spelldmg = GUICtrlCreateInput($spelldmg, 112, 48, 33, 30)
- $Label4 = GUICtrlCreateLabel("Defense Spell:", 0, 80, 111, 30, $WS_BORDER)
- GUICtrlSetFont(-1, 12, 800, 0, "Palatino Linotype")
- $spelldef = GUICtrlCreateInput($spelldef, 112, 80, 33, 30)
- $Label5 = GUICtrlCreateLabel("Buff:", 0, 112, 111, 30, $WS_BORDER)
- GUICtrlSetFont(-1, 12, 800, 0, "Palatino Linotype")
- $spellbuff = GUICtrlCreateInput($spellbuff, 112, 112, 33, 30)
- $Label6 = GUICtrlCreateLabel("Auto Login", 0, 184, 149, 22, $WS_BORDER)
- GUICtrlSetFont(-1, 10, 800, 0, "Palatino Linotype")
- $pw = GUICtrlCreateInput($pw, 0, 208, 149, 21)
- GUISetState(@SW_SHOW)
- While 1
- $nMsg = GUIGetMsg()
- Switch $nMsg
- Case $GUI_EVENT_CLOSE
- Exit
- Case $Button1
- tt("3")
- sleep (1000)
- tt("2")
- sleep (1000)
- GUISetState(@SW_HIDE)
- tt("1")
- sleep (1000)
- where()
- EndSwitch
- WEnd
- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
- func where()
- sleep(random(10, 30))
- PixelSearch (601 , 922, 603, 923, 0x8A1110)
- If not @error then
- login()
- else
- PixelSearch (568, 399, 570, 405, 0xF09901)
- If not @error then
- logg("DC")
- MouseClick("left" ,630, 600)
- sleep(10000)
- MouseClick("left" ,630, 600)
- send("{Esc}")
- sleep(10000)
- where()
- else
- PixelSearch (236, 192, 239, 194, 0xD6D7D6)
- If not @error then
- menu()
- else
- PixelSearch (320, 313, 322, 315, 0xFFFFFF)
- If not @error then
- tt("down")
- relog()
- else
- PixelSearch (1157, 17, 1159, 18, 0xFFFFFF)
- If not @error then
- gates()
- Else
- tt("Error 37")
- MouseMove (630, 615, random(10, 30))
- MouseClick("left")
- sleep(random(7000, 8000))
- MouseClick("left")
- send("{Esc}")
- relog()
- endif
- endif
- endif
- endif
- endif
- endfunc
- func menu()
- sleep(random(10, 30))
- PixelSearch (236, 192, 239, 194, 0xD6D7D6)
- If not @error then
- tt("Changing Quest")
- MouseMove (243+Random(-1,2), 461+Random(-1,2), random(10, 30))
- MouseClick("left")
- sleep(random(200, 300))
- MouseMove (120+Random(-1,2), 480+Random(-1,2), random(10, 30))
- MouseWheel ("down", 1)
- sleep(100)
- MouseWheel ("down", 1)
- sleep(100)
- MouseWheel ("down", 1)
- sleep(100)
- MouseWheel ("down", 1)
- sleep(100)
- MouseWheel ("down", 1)
- sleep(100)
- MouseWheel ("down", 1)
- sleep(100)
- MouseWheel ("down", 1)
- sleep(random(300, 400))
- MouseClick("left")
- sleep(random(300, 500))
- MouseMove(878+Random(-1,2),823+Random(-1,2), random(10, 30))
- MouseClick("left")
- sleep(random(200, 400))
- MouseMove(565+Random(-1,2),607+Random(-1,2), random(10, 30))
- MouseClick("left")
- sleep(random(300, 500))
- MouseMove(312+Random(-1,2),392+Random(-1,2), random(10, 30))
- MouseClick("left")
- ladt()
- Else
- where()
- endif
- endfunc
- func ladt()
- tt("loading")
- sleep (5000)
- PixelSearch (1157, 17, 1159, 18, 0xFFFFFF)
- If not @error then
- gates()
- else
- sleep(7000)
- where()
- EndIf
- endfunc
- func gates()
- sleep(random(5, 10))
- PixelSearch (895, 34, 897, 36, 0xFFF000)
- If not @error then
- tt("Repair")
- reppen()
- else
- PixelSearch (1157, 17, 1159, 18, 0xFFFFFF)
- If not @error then
- tt("Gates")
- sleep(random(800, 1000))
- $rndgates = random (1, 3, 1)
- if $rndgates = 1 then
- tt("Gates - Move 1")
- send (GUICtrlRead($spellbuff))
- MouseMove (80+Random(-1,2), 121+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(3600, 3765))
- MouseMove (32+Random(-1,2), 206+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(3230, 3665))
- searchstein()
- elseif $rndgates = 2 then
- tt("Gates - Move 2")
- MouseMove (20+Random(-1,2), 121+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(3000, 3265))
- MouseMove (50+Random(-1,2), 300+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(3130, 3565))
- send (GUICtrlRead($spellbuff))
- searchstein()
- elseif $rndgates = 3 then
- tt("Gates - Move 3")
- MouseMove (100+Random(-1,2), 121+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(3300, 3465))
- MouseMove (200+Random(-1,2), 400+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(230, 265))
- send (GUICtrlRead($spellbuff))
- sleep(random(2430, 2565))
- searchstein()
- endif
- endif
- endif
- endfunc
- func searchstein()
- $PixPos = PixelSearch(40, 100, 1050, 800, 0x4569FF, 5)
- If Not @error Then
- MouseClick("left", $PixPos[0], $PixPos[1], 1, random(3, 7))
- tt("WP found")
- sleep(random(3700, 3965))
- stein()
- else
- tt("WP?!?!?!?! Error 75")
- sleep (1000)
- relog()
- EndIf
- endfunc
- func stein()
- PixelSearch (185, 265, 195, 270, 0x00FF00)
- If not @error then
- tt("Checkpoint 1 - OK")
- $rnc = Random(1,2,1)
- If $rnc = 1 Then
- send("{Esc}")
- sleep(random(660, 765))
- MouseMove(164+Random(-1,2),160+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(4250, 4865))
- send("{9}")
- sleep(random(160, 265))
- send("{9}")
- sleep(random(160, 265))
- send("{9}")
- sleep(random(160, 265))
- send("{9}")
- sleep(random(160, 265))
- send("{9}")
- sleep(random(3100, 3665))
- MouseMove(779+Random(-1,2),372+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(800, 965))
- send("{ESC}")
- sleep(random(100, 235))
- send("{ESC}")
- sleep(random(600, 765))
- MouseMove(194+Random(-1,2),146+Random(-1,2), random(10, 30))
- MouseClick("left")
- sleep(random(4000, 4100))
- tt("Video?")
- video()
- ElseIf $rnc = 2 Then
- MouseMove(557+Random(-1,2),335+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(1250, 1365))
- MouseMove(242+Random(-1,2),272+Random(-1,2), random(3, 7))
- MouseClick("left")
- sleep(random(1300, 1465))
- send("{9}")
- sleep(random(160, 265))
- send("{9}")
- sleep(random(160, 265))
- send("{9}")
- sleep(random(160, 265))
- send("{9}")
- sleep(random(160, 265))
- send("{9}")
- sleep(random(3100, 3665))
- MouseMove(723+Random(-1,2),358+Random(-1,2), random(10, 30))
- MouseClick("left")
- sleep(random(800, 965))
- send("{ESC}")
- sleep(random(100, 235))
- send("{ESC}")
- sleep(random(600, 765))
- MouseMove(194+Random(-1,2),146+Random(-1,2), random(10, 30))
- MouseClick("left")
- sleep(random(7800, 8000))
- tt("Video?")
- video()
- endif
- else
- tt("Checkpoint 1 - Fail")
- logg("Checkpoint 1 - Fail")
- sleep(500)
- relog()
- endif
- endfunc
- func video()
- $i = 1
- PixelSearch (334, 50, 337, 53, 0x000000) ;Video schwarz
- If not @error then
- tt("Checkpoint 2 - OK")
- Send("{esc}")
- sleep(random(500, 700))
- MouseMove(510+Random(-1,2),344+Random(-1,2), random(2, 3))
- MouseClick("left")
- sleep(random(2800, 2850))
- $rnd = Random(1,3,1)
- If $rnd = 1 Then
- tt("Spot 1")
- MouseMove(1223+Random(-10,20),880+Random(-10,20), random(1, 2))
- MouseClick("left")
- sleep(random(2100, 2200))
- MouseMove(1146+Random(-10,20),836+Random(-10,20), random(1, 2))
- MouseClick("left")
- sleep(random(1500, 2100))
- fight1()
- ElseIf $rnd = 2 Then
- tt("Spot 2")
- MouseMove(1190+Random(-10,20),203+Random(-10,20), random(1, 3))
- MouseClick("left")
- sleep(random(1200, 1300))
- MouseMove(1189+Random(-10,20),203+Random(-10,20), random(1, 2))
- MouseClick("left")
- sleep(random(2100, 2200))
- fight2()
- ElseIf $rnd = 3 Then
- tt("Spot 3")
- MouseMove(520+Random(-10,20),360+Random(-10,20), random(2, 3))
- MouseClick("left")
- sleep(random(1200, 1700))
- MouseMove(9+Random(-10,20),197+Random(-10,20), random(2, 5))
- MouseClick("left")
- sleep(random(2200, 2400))
- fight3()
- endif
- Else
- tt("Checkpoint 2 - Fail")
- logg("Checkpoint 2 - Fail")
- sleep(1000)
- relog()
- endif
- endfunc
- func fight1()
- $i += 1
- if $i =12 Then
- tt("bug")
- sleep(1000)
- _ScreenCapture_Capture ($Name & ".jpg")
- logg("Bug - Relog")
- MouseMove (630, 615, random(10, 30))
- MouseClick("left")
- sleep(random(7000, 8000))
- MouseClick("left")
- send("{Esc}")
- relog()
- else
- PixelSearch (320, 313, 322, 315, 0xFFFFFF) ;down
- If not @error then
- tt("down")
- logg("U DIED - Fight 1")
- sleep(1000)
- relog()
- else
- PixelSearch (1056, 410, 1058, 412, 0xFFFFFF) ;Boss down
- If not @error then
- tt("Boss down")
- logg("Boss down - Fight 1")
- Sleep (1000)
- MouseMove(290,133, random(1, 3))
- Mouseclick("left")
- sleep(random(1000, 1200))
- relog()
- else
- tt("Fight 1 - Try: " & $i)
- MouseMove(261,252, random(1, 3))
- MouseDown("Right")
- sleep(random(2400, 2600))
- MouseUp("Right")
- sleep(random(100, 200))
- send (GUICtrlRead($spelldef))
- sleep(random(100, 200))
- send (GUICtrlRead($spelldmg))
- sleep(random(100, 200))
- fight1()
- endif
- endif
- endif
- endfunc
- func fight2()
- $i += 1
- if $i =15 Then
- tt("bug")
- sleep(1000)
- _ScreenCapture_Capture ($Name & ".jpg")
- logg("Bug - Relog")
- MouseMove (630, 615, random(10, 30))
- MouseClick("left")
- sleep(random(7000, 8000))
- MouseClick("left")
- send("{Esc}")
- relog()
- else
- PixelSearch (320, 313, 322, 315, 0xFFFFFF) ;down
- If not @error then
- tt("down")
- logg("U DIED - Fight 2")
- sleep(1000)
- relog()
- else
- PixelSearch (1056, 410, 1058, 412, 0xFFFFFF) ;Boss down
- If not @error then
- tt("Boss down")
- logg("Boss down - Fight 2")
- MouseMove(200,810, random(1, 3))
- Mouseclick("left")
- sleep(random(1000, 1200))
- relog()
- else
- tt("Fight 2 - Try: " & $i)
- MouseMove(361,626, random(1, 3))
- MouseDown("Right")
- sleep(random(2000, 2400))
- MouseUp("Right")
- sleep(random(300, 400))
- send (GUICtrlRead($spelldef))
- sleep(random(400, 500))
- send (GUICtrlRead($spelldmg))
- sleep(random(400, 500))
- fight2()
- endif
- endif
- endif
- endfunc
- func fight3()
- $i += 1
- if $i =12 Then
- tt("bug")
- sleep(1000)
- _ScreenCapture_Capture ($name & ".jpg")
- logg("Bug - Relog")
- MouseMove (630, 615, random(10, 30))
- MouseClick("left")
- sleep(random(7000, 8000))
- MouseClick("left")
- send("{Esc}")
- relog()
- else
- PixelSearch (320, 313, 322, 315, 0xFFFFFF) ;down
- If not @error then
- tt("down")
- logg("U DIED - Fight 3")
- sleep(1000)
- relog()
- else
- PixelSearch (1056, 410, 1058, 412, 0xFFFFFF) ;Boss down
- If not @error then
- tt("Boss down")
- logg("Boss down - Fight 3")
- Sleep (1000)
- MouseMove(900,700, random(1, 3))
- Mouseclick("left")
- sleep(random(800, 1200))
- relog()
- else
- tt("Fight 3 - Try: " & $i)
- MouseMove(956,576, random(1, 3))
- MouseDown("Right")
- sleep(random(2000, 2300))
- MouseUp("Right")
- sleep(random(100, 300))
- send (GUICtrlRead($spelldef))
- sleep(random(500, 600))
- send (GUICtrlRead($spelldmg))
- fight3()
- endif
- endif
- endif
- endfunc
- func reppen()
- send("{t}")
- sleep(random(12000, 17600))
- MouseMove(35+Random(-1,2),297+Random(-1,2), random(10, 30))
- MouseClick("left")
- Sleep(3234)
- MouseMove(23+Random(-1,2),499+Random(-1,2), random(10, 30))
- MouseClick("left")
- Sleep(2081)
- MouseMove(145+Random(-1,2),346+Random(-1,2), random(10, 30))
- MouseClick("left")
- Sleep(3114)
- MouseMove(475+Random(-1,2),577+Random(-1,2), random(10, 30))
- MouseClick("left")
- Sleep(1330)
- MouseMove(304+Random(-1,2),502+Random(-1,2), random(10, 30))
- MouseClick("left")
- logg("repaired")
- relog()
- endfunc
- func relog()
- $x += 1
- if $x = 30 Then
- $rnr = Random(1,2,1)
- If $rnr = 1 Then
- tt("time to rest")
- logg("break, sTylBot sleeping")
- MouseMove(916,970, random(10, 30))
- MouseClick("left")
- sleep(random(1000, 4000))
- MouseMove(631,545, random(10, 30))
- MouseClick("left")
- $x = 1
- sleep(random(2600000, 3000000))
- where()
- ElseIf $rnr = 2 Then
- sleep(17000)
- logg("no break")
- $x = 1
- where()
- endif
- else
- MouseMove(916,970, random(10, 30))
- MouseClick("left")
- sleep(random(1000, 4000))
- MouseMove(631,545, random(10, 30))
- MouseClick("left")
- tt("relogging")
- sleep(random(16000, 18000))
- where()
- endif
- endfunc
- func login()
- PixelSearch (601, 922, 603, 923, 0x8A1110)
- If not @error then
- $l += 1
- if $l = 15 Then
- logg("Login - Failed")
- Exit
- else
- tt("Login")
- logg("Login")
- sleep(random(3000, 4000))
- MouseClick("left", 500, 660)
- sleep(500)
- send (GUICtrlRead($pw))
- MouseClick("left", 600, 800)
- sleep (12000)
- where()
- endif
- else
- where()
- endif
- endfunc
- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
- Func Stop()
- Exit
- EndFunc
- Func tt($text)
- ToolTip($text ,20,3)
- EndFunc
- Func logg($Data)
- $FileName = @ScriptDir & '\Log.txt'
- $hFile = FileOpen($FileName, 1)
- $Data = _Now() & ' - ' & $Data
- FileWriteLine($hFile, $Data)
- FileClose($hFile)
- EndFunc
- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement