Advertisement
Guest User

Stylerr Iskatu Autoit

a guest
Jun 14th, 2012
440
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 13.33 KB | None | 0 0
  1. #include <ButtonConstants.au3>
  2. #include <EditConstants.au3>
  3. #include <GUIConstantsEx.au3>
  4. #include <StaticConstants.au3>
  5. #include <WindowsConstants.au3>
  6. #include <ScreenCapture.au3>
  7. #include <Date.au3>
  8. $RND = Random(1, 2, 1)
  9. $name = random(1,1000)
  10. $i = 1
  11. $l = 1
  12. $x = 1
  13. dim $spelldmg
  14. dim $spellbuff
  15. dim $spelldef
  16. dim $pw
  17. HotKeySet("l", "Stop")
  18.  
  19. $z4x = GUICreate("Paint", 151, 263, 510, 422)
  20. GUISetFont(8, 800, 0, "MS Sans Serif")
  21. GUISetBkColor(0xFFFFFF)
  22. $Button1 = GUICtrlCreateButton("Start", 32, 232, 75, 25, $WS_BORDER)
  23. GUICtrlSetBkColor(-1, 0xF4F7FC)
  24. $Label1 = GUICtrlCreateLabel("sTylBot 0.1", 0, 0, 149, 17)
  25. $Label2 = GUICtrlCreateLabel("1280*1024Engl. Client", 0, 24, 149, 17)
  26. $Label3 = GUICtrlCreateLabel("Damage Spell:", 0, 48, 111, 30, $WS_BORDER)
  27. GUICtrlSetFont(-1, 12, 800, 0, "Palatino Linotype")
  28. $spelldmg = GUICtrlCreateInput($spelldmg, 112, 48, 33, 30)
  29. $Label4 = GUICtrlCreateLabel("Defense Spell:", 0, 80, 111, 30, $WS_BORDER)
  30. GUICtrlSetFont(-1, 12, 800, 0, "Palatino Linotype")
  31. $spelldef = GUICtrlCreateInput($spelldef, 112, 80, 33, 30)
  32. $Label5 = GUICtrlCreateLabel("Buff:", 0, 112, 111, 30, $WS_BORDER)
  33. GUICtrlSetFont(-1, 12, 800, 0, "Palatino Linotype")
  34. $spellbuff = GUICtrlCreateInput($spellbuff, 112, 112, 33, 30)
  35. $Label6 = GUICtrlCreateLabel("Auto Login", 0, 184, 149, 22, $WS_BORDER)
  36. GUICtrlSetFont(-1, 10, 800, 0, "Palatino Linotype")
  37. $pw = GUICtrlCreateInput($pw, 0, 208, 149, 21)
  38. GUISetState(@SW_SHOW)
  39. While 1
  40. $nMsg = GUIGetMsg()
  41. Switch $nMsg
  42. Case $GUI_EVENT_CLOSE
  43. Exit
  44. Case $Button1
  45. tt("3")
  46. sleep (1000)
  47. tt("2")
  48. sleep (1000)
  49. GUISetState(@SW_HIDE)
  50. tt("1")
  51. sleep (1000)
  52. where()
  53. EndSwitch
  54. WEnd
  55. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  56. func where()
  57. sleep(random(10, 30))
  58. PixelSearch (601 , 922, 603, 923, 0x8A1110)
  59. If not @error then
  60. login()
  61. else
  62. PixelSearch (568, 399, 570, 405, 0xF09901)
  63. If not @error then
  64. logg("DC")
  65. MouseClick("left" ,630, 600)
  66. sleep(10000)
  67. MouseClick("left" ,630, 600)
  68. send("{Esc}")
  69. sleep(10000)
  70. where()
  71. else
  72. PixelSearch (236, 192, 239, 194, 0xD6D7D6)
  73. If not @error then
  74. menu()
  75. else
  76. PixelSearch (320, 313, 322, 315, 0xFFFFFF)
  77. If not @error then
  78. tt("down")
  79. relog()
  80. else
  81. PixelSearch (1157, 17, 1159, 18, 0xFFFFFF)
  82. If not @error then
  83. gates()
  84. Else
  85. tt("Error 37")
  86. MouseMove (630, 615, random(10, 30))
  87. MouseClick("left")
  88. sleep(random(7000, 8000))
  89. MouseClick("left")
  90. send("{Esc}")
  91. relog()
  92.  
  93. endif
  94. endif
  95. endif
  96. endif
  97. endif
  98. endfunc
  99.  
  100. func menu()
  101. sleep(random(10, 30))
  102. PixelSearch (236, 192, 239, 194, 0xD6D7D6)
  103. If not @error then
  104. tt("Changing Quest")
  105. MouseMove (243+Random(-1,2), 461+Random(-1,2), random(10, 30))
  106. MouseClick("left")
  107. sleep(random(200, 300))
  108. MouseMove (120+Random(-1,2), 480+Random(-1,2), random(10, 30))
  109. MouseWheel ("down", 1)
  110. sleep(100)
  111. MouseWheel ("down", 1)
  112. sleep(100)
  113. MouseWheel ("down", 1)
  114. sleep(100)
  115. MouseWheel ("down", 1)
  116. sleep(100)
  117. MouseWheel ("down", 1)
  118. sleep(100)
  119. MouseWheel ("down", 1)
  120. sleep(100)
  121. MouseWheel ("down", 1)
  122. sleep(random(300, 400))
  123. MouseClick("left")
  124. sleep(random(300, 500))
  125. MouseMove(878+Random(-1,2),823+Random(-1,2), random(10, 30))
  126. MouseClick("left")
  127. sleep(random(200, 400))
  128. MouseMove(565+Random(-1,2),607+Random(-1,2), random(10, 30))
  129. MouseClick("left")
  130. sleep(random(300, 500))
  131. MouseMove(312+Random(-1,2),392+Random(-1,2), random(10, 30))
  132. MouseClick("left")
  133. ladt()
  134. Else
  135. where()
  136. endif
  137. endfunc
  138.  
  139. func ladt()
  140. tt("loading")
  141. sleep (5000)
  142. PixelSearch (1157, 17, 1159, 18, 0xFFFFFF)
  143. If not @error then
  144. gates()
  145. else
  146. sleep(7000)
  147. where()
  148. EndIf
  149. endfunc
  150.  
  151. func gates()
  152. sleep(random(5, 10))
  153. PixelSearch (895, 34, 897, 36, 0xFFF000)
  154. If not @error then
  155. tt("Repair")
  156. reppen()
  157. else
  158. PixelSearch (1157, 17, 1159, 18, 0xFFFFFF)
  159. If not @error then
  160. tt("Gates")
  161. sleep(random(800, 1000))
  162. $rndgates = random (1, 3, 1)
  163. if $rndgates = 1 then
  164. tt("Gates - Move 1")
  165. send (GUICtrlRead($spellbuff))
  166. MouseMove (80+Random(-1,2), 121+Random(-1,2), random(3, 7))
  167. MouseClick("left")
  168. sleep(random(3600, 3765))
  169. MouseMove (32+Random(-1,2), 206+Random(-1,2), random(3, 7))
  170. MouseClick("left")
  171. sleep(random(3230, 3665))
  172. searchstein()
  173. elseif $rndgates = 2 then
  174. tt("Gates - Move 2")
  175. MouseMove (20+Random(-1,2), 121+Random(-1,2), random(3, 7))
  176. MouseClick("left")
  177. sleep(random(3000, 3265))
  178. MouseMove (50+Random(-1,2), 300+Random(-1,2), random(3, 7))
  179. MouseClick("left")
  180. sleep(random(3130, 3565))
  181. send (GUICtrlRead($spellbuff))
  182. searchstein()
  183. elseif $rndgates = 3 then
  184. tt("Gates - Move 3")
  185. MouseMove (100+Random(-1,2), 121+Random(-1,2), random(3, 7))
  186. MouseClick("left")
  187. sleep(random(3300, 3465))
  188. MouseMove (200+Random(-1,2), 400+Random(-1,2), random(3, 7))
  189. MouseClick("left")
  190. sleep(random(230, 265))
  191. send (GUICtrlRead($spellbuff))
  192. sleep(random(2430, 2565))
  193. searchstein()
  194. endif
  195. endif
  196. endif
  197. endfunc
  198.  
  199. func searchstein()
  200. $PixPos = PixelSearch(40, 100, 1050, 800, 0x4569FF, 5)
  201. If Not @error Then
  202. MouseClick("left", $PixPos[0], $PixPos[1], 1, random(3, 7))
  203. tt("WP found")
  204. sleep(random(3700, 3965))
  205. stein()
  206. else
  207. tt("WP?!?!?!?! Error 75")
  208. sleep (1000)
  209. relog()
  210. EndIf
  211. endfunc
  212.  
  213. func stein()
  214. PixelSearch (185, 265, 195, 270, 0x00FF00)
  215. If not @error then
  216. tt("Checkpoint 1 - OK")
  217. $rnc = Random(1,2,1)
  218.  
  219. If $rnc = 1 Then
  220. send("{Esc}")
  221. sleep(random(660, 765))
  222. MouseMove(164+Random(-1,2),160+Random(-1,2), random(3, 7))
  223. MouseClick("left")
  224. sleep(random(4250, 4865))
  225. send("{9}")
  226. sleep(random(160, 265))
  227. send("{9}")
  228. sleep(random(160, 265))
  229. send("{9}")
  230. sleep(random(160, 265))
  231. send("{9}")
  232. sleep(random(160, 265))
  233. send("{9}")
  234. sleep(random(3100, 3665))
  235. MouseMove(779+Random(-1,2),372+Random(-1,2), random(3, 7))
  236. MouseClick("left")
  237. sleep(random(800, 965))
  238. send("{ESC}")
  239. sleep(random(100, 235))
  240. send("{ESC}")
  241. sleep(random(600, 765))
  242. MouseMove(194+Random(-1,2),146+Random(-1,2), random(10, 30))
  243. MouseClick("left")
  244. sleep(random(4000, 4100))
  245. tt("Video?")
  246. video()
  247.  
  248. ElseIf $rnc = 2 Then
  249. MouseMove(557+Random(-1,2),335+Random(-1,2), random(3, 7))
  250. MouseClick("left")
  251. sleep(random(1250, 1365))
  252. MouseMove(242+Random(-1,2),272+Random(-1,2), random(3, 7))
  253. MouseClick("left")
  254. sleep(random(1300, 1465))
  255. send("{9}")
  256. sleep(random(160, 265))
  257. send("{9}")
  258. sleep(random(160, 265))
  259. send("{9}")
  260. sleep(random(160, 265))
  261. send("{9}")
  262. sleep(random(160, 265))
  263. send("{9}")
  264. sleep(random(3100, 3665))
  265. MouseMove(723+Random(-1,2),358+Random(-1,2), random(10, 30))
  266. MouseClick("left")
  267. sleep(random(800, 965))
  268. send("{ESC}")
  269. sleep(random(100, 235))
  270. send("{ESC}")
  271. sleep(random(600, 765))
  272. MouseMove(194+Random(-1,2),146+Random(-1,2), random(10, 30))
  273. MouseClick("left")
  274. sleep(random(7800, 8000))
  275. tt("Video?")
  276. video()
  277. endif
  278. else
  279. tt("Checkpoint 1 - Fail")
  280. logg("Checkpoint 1 - Fail")
  281. sleep(500)
  282. relog()
  283. endif
  284. endfunc
  285.  
  286.  
  287. func video()
  288. $i = 1
  289. PixelSearch (334, 50, 337, 53, 0x000000) ;Video schwarz
  290. If not @error then
  291. tt("Checkpoint 2 - OK")
  292. Send("{esc}")
  293. sleep(random(500, 700))
  294. MouseMove(510+Random(-1,2),344+Random(-1,2), random(2, 3))
  295. MouseClick("left")
  296. sleep(random(2800, 2850))
  297. $rnd = Random(1,3,1)
  298.  
  299. If $rnd = 1 Then
  300. tt("Spot 1")
  301. MouseMove(1223+Random(-10,20),880+Random(-10,20), random(1, 2))
  302. MouseClick("left")
  303. sleep(random(2100, 2200))
  304. MouseMove(1146+Random(-10,20),836+Random(-10,20), random(1, 2))
  305. MouseClick("left")
  306. sleep(random(1500, 2100))
  307. fight1()
  308. ElseIf $rnd = 2 Then
  309. tt("Spot 2")
  310. MouseMove(1190+Random(-10,20),203+Random(-10,20), random(1, 3))
  311. MouseClick("left")
  312. sleep(random(1200, 1300))
  313. MouseMove(1189+Random(-10,20),203+Random(-10,20), random(1, 2))
  314. MouseClick("left")
  315. sleep(random(2100, 2200))
  316. fight2()
  317. ElseIf $rnd = 3 Then
  318. tt("Spot 3")
  319. MouseMove(520+Random(-10,20),360+Random(-10,20), random(2, 3))
  320. MouseClick("left")
  321. sleep(random(1200, 1700))
  322. MouseMove(9+Random(-10,20),197+Random(-10,20), random(2, 5))
  323. MouseClick("left")
  324. sleep(random(2200, 2400))
  325. fight3()
  326. endif
  327. Else
  328. tt("Checkpoint 2 - Fail")
  329. logg("Checkpoint 2 - Fail")
  330. sleep(1000)
  331. relog()
  332. endif
  333. endfunc
  334.  
  335. func fight1()
  336. $i += 1
  337. if $i =12 Then
  338. tt("bug")
  339. sleep(1000)
  340. _ScreenCapture_Capture ($Name & ".jpg")
  341. logg("Bug - Relog")
  342. MouseMove (630, 615, random(10, 30))
  343. MouseClick("left")
  344. sleep(random(7000, 8000))
  345. MouseClick("left")
  346. send("{Esc}")
  347. relog()
  348. else
  349. PixelSearch (320, 313, 322, 315, 0xFFFFFF) ;down
  350. If not @error then
  351. tt("down")
  352. logg("U DIED - Fight 1")
  353. sleep(1000)
  354. relog()
  355. else
  356. PixelSearch (1056, 410, 1058, 412, 0xFFFFFF) ;Boss down
  357. If not @error then
  358. tt("Boss down")
  359. logg("Boss down - Fight 1")
  360. Sleep (1000)
  361. MouseMove(290,133, random(1, 3))
  362. Mouseclick("left")
  363. sleep(random(1000, 1200))
  364. relog()
  365. else
  366. tt("Fight 1 - Try: " & $i)
  367. MouseMove(261,252, random(1, 3))
  368. MouseDown("Right")
  369. sleep(random(2400, 2600))
  370. MouseUp("Right")
  371. sleep(random(100, 200))
  372. send (GUICtrlRead($spelldef))
  373. sleep(random(100, 200))
  374. send (GUICtrlRead($spelldmg))
  375. sleep(random(100, 200))
  376. fight1()
  377. endif
  378. endif
  379. endif
  380. endfunc
  381.  
  382. func fight2()
  383. $i += 1
  384. if $i =15 Then
  385. tt("bug")
  386. sleep(1000)
  387. _ScreenCapture_Capture ($Name & ".jpg")
  388. logg("Bug - Relog")
  389. MouseMove (630, 615, random(10, 30))
  390. MouseClick("left")
  391. sleep(random(7000, 8000))
  392. MouseClick("left")
  393. send("{Esc}")
  394. relog()
  395. else
  396. PixelSearch (320, 313, 322, 315, 0xFFFFFF) ;down
  397. If not @error then
  398. tt("down")
  399. logg("U DIED - Fight 2")
  400. sleep(1000)
  401. relog()
  402. else
  403. PixelSearch (1056, 410, 1058, 412, 0xFFFFFF) ;Boss down
  404. If not @error then
  405. tt("Boss down")
  406. logg("Boss down - Fight 2")
  407. MouseMove(200,810, random(1, 3))
  408. Mouseclick("left")
  409. sleep(random(1000, 1200))
  410. relog()
  411. else
  412.  
  413. tt("Fight 2 - Try: " & $i)
  414. MouseMove(361,626, random(1, 3))
  415. MouseDown("Right")
  416. sleep(random(2000, 2400))
  417. MouseUp("Right")
  418. sleep(random(300, 400))
  419. send (GUICtrlRead($spelldef))
  420. sleep(random(400, 500))
  421. send (GUICtrlRead($spelldmg))
  422. sleep(random(400, 500))
  423. fight2()
  424. endif
  425. endif
  426. endif
  427. endfunc
  428.  
  429. func fight3()
  430. $i += 1
  431. if $i =12 Then
  432. tt("bug")
  433. sleep(1000)
  434. _ScreenCapture_Capture ($name & ".jpg")
  435. logg("Bug - Relog")
  436. MouseMove (630, 615, random(10, 30))
  437. MouseClick("left")
  438. sleep(random(7000, 8000))
  439. MouseClick("left")
  440. send("{Esc}")
  441. relog()
  442. else
  443. PixelSearch (320, 313, 322, 315, 0xFFFFFF) ;down
  444. If not @error then
  445. tt("down")
  446. logg("U DIED - Fight 3")
  447. sleep(1000)
  448. relog()
  449. else
  450. PixelSearch (1056, 410, 1058, 412, 0xFFFFFF) ;Boss down
  451. If not @error then
  452. tt("Boss down")
  453. logg("Boss down - Fight 3")
  454. Sleep (1000)
  455. MouseMove(900,700, random(1, 3))
  456. Mouseclick("left")
  457. sleep(random(800, 1200))
  458. relog()
  459. else
  460.  
  461. tt("Fight 3 - Try: " & $i)
  462. MouseMove(956,576, random(1, 3))
  463. MouseDown("Right")
  464. sleep(random(2000, 2300))
  465. MouseUp("Right")
  466. sleep(random(100, 300))
  467. send (GUICtrlRead($spelldef))
  468. sleep(random(500, 600))
  469. send (GUICtrlRead($spelldmg))
  470. fight3()
  471. endif
  472. endif
  473. endif
  474. endfunc
  475.  
  476. func reppen()
  477. send("{t}")
  478. sleep(random(12000, 17600))
  479.  
  480. MouseMove(35+Random(-1,2),297+Random(-1,2), random(10, 30))
  481. MouseClick("left")
  482. Sleep(3234)
  483. MouseMove(23+Random(-1,2),499+Random(-1,2), random(10, 30))
  484. MouseClick("left")
  485. Sleep(2081)
  486. MouseMove(145+Random(-1,2),346+Random(-1,2), random(10, 30))
  487. MouseClick("left")
  488. Sleep(3114)
  489. MouseMove(475+Random(-1,2),577+Random(-1,2), random(10, 30))
  490. MouseClick("left")
  491. Sleep(1330)
  492. MouseMove(304+Random(-1,2),502+Random(-1,2), random(10, 30))
  493. MouseClick("left")
  494. logg("repaired")
  495. relog()
  496. endfunc
  497.  
  498. func relog()
  499. $x += 1
  500. if $x = 30 Then
  501. $rnr = Random(1,2,1)
  502. If $rnr = 1 Then
  503. tt("time to rest")
  504. logg("break, sTylBot sleeping")
  505. MouseMove(916,970, random(10, 30))
  506. MouseClick("left")
  507. sleep(random(1000, 4000))
  508. MouseMove(631,545, random(10, 30))
  509. MouseClick("left")
  510. $x = 1
  511. sleep(random(2600000, 3000000))
  512. where()
  513. ElseIf $rnr = 2 Then
  514. sleep(17000)
  515. logg("no break")
  516. $x = 1
  517. where()
  518. endif
  519.  
  520. else
  521. MouseMove(916,970, random(10, 30))
  522. MouseClick("left")
  523. sleep(random(1000, 4000))
  524. MouseMove(631,545, random(10, 30))
  525. MouseClick("left")
  526. tt("relogging")
  527. sleep(random(16000, 18000))
  528. where()
  529. endif
  530. endfunc
  531.  
  532. func login()
  533. PixelSearch (601, 922, 603, 923, 0x8A1110)
  534. If not @error then
  535.  
  536. $l += 1
  537. if $l = 15 Then
  538. logg("Login - Failed")
  539. Exit
  540. else
  541. tt("Login")
  542. logg("Login")
  543. sleep(random(3000, 4000))
  544. MouseClick("left", 500, 660)
  545. sleep(500)
  546. send (GUICtrlRead($pw))
  547. MouseClick("left", 600, 800)
  548. sleep (12000)
  549. where()
  550. endif
  551. else
  552. where()
  553. endif
  554. endfunc
  555.  
  556. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  557. Func Stop()
  558. Exit
  559. EndFunc
  560.  
  561. Func tt($text)
  562. ToolTip($text ,20,3)
  563. EndFunc
  564.  
  565. Func logg($Data)
  566. $FileName = @ScriptDir & '\Log.txt'
  567. $hFile = FileOpen($FileName, 1)
  568. $Data = _Now() & ' - ' & $Data
  569. FileWriteLine($hFile, $Data)
  570. FileClose($hFile)
  571. EndFunc
  572.  
  573. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement