Advertisement
Guest User

Untitled

a guest
May 8th, 2017
593
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 13.92 KB | None | 0 0
  1. program AAAlcher;
  2. {.include SRL\SRL\Misc\Smart.scar}
  3. {.include SRL/SRL.scar}
  4.  
  5.  
  6. //thanks to superbatman, for solving two bugs that i couldnt figure out
  7.  
  8.  
  9.  
  10. var
  11. frmDesign : TForm;
  12. Label1 : TLabel;
  13. Label2 : TLabel;
  14. Label3 : TLabel;
  15. Label4 : TLabel;
  16. Label5 : TLabel;
  17. Label6 : TLabel;
  18. Label7 : TLabel;
  19. Label8 : TLabel;
  20. Label9 : TLabel;
  21. Label10 : TLabel;
  22. Label11 : TLabel;
  23. Label12 : TLabel;
  24. Label13 : TLabel;
  25. Button1 : TButton;
  26. UserEdit : TEdit;
  27. PassEdit : TEdit;
  28. NickEdit : TEdit;
  29. STEdit : TEdit;
  30. SFEdit : TEdit;
  31. AlchEdit : TEdit;
  32. SrlIdEdit : TEdit;
  33. SrlPEdit : TEdit;
  34. smartedit : TEdit;
  35. AntiBEdit : TEdit;
  36. HAedit : TEdit;
  37. SleepEdit : TEdit;
  38. SrlIdName, SrlPass, SmartB, AntiBanB, AlchB, SleepB: String;
  39. Username, Password, Alchs, Nick, SleepT, SleepF: String;
  40. SRL_Time, Counter, exp, SleepN, x, y, R, RG, C : integer;
  41.  
  42. procedure prog; forward;
  43.  
  44.  
  45. procedure StartClick(sender: TObject);
  46. begin
  47. Writeln('Get Ready To Alch!');
  48. frmDesign.ModalResult:= mrOk; // Closes the form
  49. Username := UserEdit.Text;//
  50. Password := PassEdit.Text;//
  51. Nick := NickEdit.Text;//
  52. Alchs := AlchEdit.Text;//
  53. SleepT := STEdit.Text;//
  54. SleepF := SFEdit.text;//
  55. SrlIdName := SrlIdEdit.Text;//
  56. SrlPass := SrlPEdit.Text;//
  57. SmartB := smartedit.Text;//
  58. AntiBanB := AntiBEdit.Text;//
  59. AlchB := HAedit.Text;//
  60. SleepB := SleepEdit.Text;
  61. WriteLn('Username = ' + Username);
  62. end;
  63.  
  64. procedure InitForm;
  65. begin
  66. ///////////////// Generated from: AAA form.dfm
  67. frmDesign := CreateForm;
  68. frmDesign.Left := 250;
  69. frmDesign.Top := 114;
  70. frmDesign.Width := 379;
  71. frmDesign.Height := 259;
  72. frmDesign.Caption := 'frmDesign';
  73. frmDesign.Color := clBtnFace;
  74. frmDesign.Font.Color := clWindowText;
  75. frmDesign.Font.Height := -11;
  76. frmDesign.Font.Name := 'MS Sans Serif';
  77. frmDesign.Font.Style := [];
  78. frmDesign.ShowHint := True;
  79. frmDesign.Visible := False;
  80. frmDesign.PixelsPerInch := 96;
  81. Label1 := TLabel.Create(frmDesign);
  82. Label1.Parent := frmDesign;
  83. Label1.Left := 24;
  84. Label1.Top := 48;
  85. Label1.Width := 53;
  86. Label1.Height := 13;
  87. Label1.Caption := 'User Name';
  88. Label2 := TLabel.Create(frmDesign);
  89. Label2.Parent := frmDesign;
  90. Label2.Left := 24;
  91. Label2.Top := 72;
  92. Label2.Width := 46;
  93. Label2.Height := 13;
  94. Label2.Caption := 'Password';
  95. Label3 := TLabel.Create(frmDesign);
  96. Label3.Parent := frmDesign;
  97. Label3.Left := 64;
  98. Label3.Top := 0;
  99. Label3.Width := 232;
  100. Label3.Height := 29;
  101. Label3.Caption := 'Awkward Auto Alcher:';
  102. Label3.Font.Color := clMaroon;
  103. Label3.Font.Height := -24;
  104. Label3.Font.Name := 'MS Sans Serif';
  105. Label3.Font.Style := [];
  106. Label3.ParentFont := False;
  107. Label4 := TLabel.Create(frmDesign);
  108. Label4.Parent := frmDesign;
  109. Label4.Left := 184;
  110. Label4.Top := 96;
  111. Label4.Width := 26;
  112. Label4.Height := 13;
  113. Label4.Caption := 'Alchs';
  114. Label5 := TLabel.Create(frmDesign);
  115. Label5.Parent := frmDesign;
  116. Label5.Left := 184;
  117. Label5.Top := 48;
  118. Label5.Width := 53;
  119. Label5.Height := 13;
  120. Label5.Caption := 'Sleep Time';
  121. Label6 := TLabel.Create(frmDesign);
  122. Label6.Parent := frmDesign;
  123. Label6.Left := 24;
  124. Label6.Top := 96;
  125. Label6.Width := 22;
  126. Label6.Height := 13;
  127. Label6.Caption := 'Nick';
  128. Label7 := TLabel.Create(frmDesign);
  129. Label7.Parent := frmDesign;
  130. Label7.Left := 184;
  131. Label7.Top := 72;
  132. Label7.Width := 45;
  133. Label7.Height := 13;
  134. Label7.Caption := 'Sleep For';
  135. Label8 := TLabel.Create(frmDesign);
  136. Label8.Parent := frmDesign;
  137. Label8.Left := 24;
  138. Label8.Top := 120;
  139. Label8.Width := 35;
  140. Label8.Height := 13;
  141. Label8.Caption := 'SRL ID';
  142. Label9 := TLabel.Create(frmDesign);
  143. Label9.Parent := frmDesign;
  144. Label9.Left := 184;
  145. Label9.Top := 120;
  146. Label9.Width := 69;
  147. Label9.Height := 13;
  148. Label9.Caption := 'SRL password';
  149. Label10 := TLabel.Create(frmDesign);
  150. Label10.Parent := frmDesign;
  151. Label10.Left := 24;
  152. Label10.Top := 144;
  153. Label10.Width := 33;
  154. Label10.Height := 13;
  155. Label10.Caption := 'Smart?';
  156. Label11 := TLabel.Create(frmDesign);
  157. Label11.Parent := frmDesign;
  158. Label11.Left := 184;
  159. Label11.Top := 144;
  160. Label11.Width := 46;
  161. Label11.Height := 13;
  162. Label11.Caption := 'Anti Ban?';
  163. Label12 := TLabel.Create(frmDesign);
  164. Label12.Parent := frmDesign;
  165. Label12.Left := 24;
  166. Label12.Top := 168;
  167. Label12.Width := 46;
  168. Label12.Height := 13;
  169. Label12.Caption := 'High Alch';
  170. Label13 := TLabel.Create(frmDesign);
  171. Label13.Parent := frmDesign;
  172. Label13.Left := 184;
  173. Label13.Top := 168;
  174. Label13.Width := 27;
  175. Label13.Height := 13;
  176. Label13.Caption := 'Sleep';
  177. Button1 := TButton.Create(frmDesign);
  178. Button1.Parent := frmDesign;
  179. Button1.Left := 112;
  180. Button1.Top := 192;
  181. Button1.Width := 145;
  182. Button1.Height := 25;
  183. Button1.Caption := 'Start';
  184. Button1.TabOrder := 8;
  185. Button1.OnClick := @StartClick;
  186. UserEdit := TEdit.Create(frmDesign);
  187. UserEdit.Parent := frmDesign;
  188. UserEdit.Left := 80;
  189. UserEdit.Top := 48;
  190. UserEdit.Width := 97;
  191. UserEdit.Height := 21;
  192. UserEdit.TabOrder := 9;
  193. PassEdit := TEdit.Create(frmDesign);
  194. PassEdit.Parent := frmDesign;
  195. PassEdit.Left := 80;
  196. PassEdit.Top := 72;
  197. PassEdit.Width := 97;
  198. PassEdit.Height := 21;
  199. PassEdit.TabOrder := 10;
  200. PassEdit.passwordchar := '*';
  201. NickEdit := TEdit.Create(frmDesign);
  202. NickEdit.Parent := frmDesign;
  203. NickEdit.Left := 80;
  204. NickEdit.Top := 96;
  205. NickEdit.Width := 97;
  206. NickEdit.Height := 21;
  207. NickEdit.TabOrder := 11;
  208. STEdit := TEdit.Create(frmDesign);
  209. STEdit.Parent := frmDesign;
  210. STEdit.Left := 240;
  211. STEdit.Top := 48;
  212. STEdit.Width := 97;
  213. STEdit.Height := 21;
  214. STEdit.TabOrder := 12;
  215. SFEdit := TEdit.Create(frmDesign);
  216. SFEdit.Parent := frmDesign;
  217. SFEdit.Left := 240;
  218. SFEdit.Top := 72;
  219. SFEdit.Width := 97;
  220. SFEdit.Height := 21;
  221. SFEdit.TabOrder := 13;
  222. AlchEdit := TEdit.Create(frmDesign);
  223. AlchEdit.Parent := frmDesign;
  224. AlchEdit.Left := 240;
  225. AlchEdit.Top := 96;
  226. AlchEdit.Width := 97;
  227. AlchEdit.Height := 21;
  228. AlchEdit.TabOrder := 14;
  229. SrlIdEdit := TEdit.Create(frmDesign);
  230. SrlIdEdit.Parent := frmDesign;
  231. SrlIdEdit.Left := 80;
  232. SrlIdEdit.Top := 120;
  233. SrlIdEdit.Width := 97;
  234. SrlIdEdit.Height := 21;
  235. SrlIdEdit.TabOrder := 15;
  236. SrlPEdit := TEdit.Create(frmDesign);
  237. SrlPEdit.Parent := frmDesign;
  238. SrlPEdit.Left := 264;
  239. SrlPEdit.Top := 120;
  240. SrlPEdit.Width := 73;
  241. SrlPEdit.Height := 21;
  242. SrlPEdit.TabOrder := 16;
  243. SrlPEdit.passwordchar := '*';
  244. smartedit := TEdit.Create(frmDesign);
  245. smartedit.Parent := frmDesign;
  246. smartedit.Left := 80;
  247. smartedit.Top := 144;
  248. smartedit.Width := 97;
  249. smartedit.Height := 21;
  250. smartedit.TabOrder := 17;
  251. smartedit.Text := 'True';
  252. AntiBEdit := TEdit.Create(frmDesign);
  253. AntiBEdit.Parent := frmDesign;
  254. AntiBEdit.Left := 240;
  255. AntiBEdit.Top := 144;
  256. AntiBEdit.Width := 97;
  257. AntiBEdit.Height := 21;
  258. AntiBEdit.TabOrder := 18;
  259. AntiBEdit.Text := 'True';
  260. HAedit := TEdit.Create(frmDesign);
  261. HAedit.Parent := frmDesign;
  262. HAedit.Left := 80;
  263. HAedit.Top := 168;
  264. HAedit.Width := 97;
  265. HAedit.Height := 21;
  266. HAedit.TabOrder := 19;
  267. HAedit.Text := 'True';
  268. SleepEdit := TEdit.Create(frmDesign);
  269. SleepEdit.Parent := frmDesign;
  270. SleepEdit.Left := 240;
  271. SleepEdit.Top := 168;
  272. SleepEdit.Width := 97;
  273. SleepEdit.Height := 21;
  274. SleepEdit.TabOrder := 20;
  275. SleepEdit.Text := 'True';
  276. end;
  277.  
  278. procedure DeclarePlayers;
  279. begin
  280. HowManyPlayers := 1;
  281. NumberOfPlayers(HowManyPlayers);
  282. CurrentPlayer := 0;
  283.  
  284. Players[0].Name := Username;
  285. Players[0].Pass := Password;
  286. Players[0].Nick := Nick;
  287. Players[0].Active := True;
  288. end;
  289.  
  290. procedure SafeInitForm;
  291. var
  292. v: TVariantArray;
  293. begin
  294. setarraylength(V, 0);
  295. ThreadSafeCall('InitForm', v);
  296. end;
  297.  
  298. procedure ShowFormModal;
  299. begin
  300. frmDesign.ShowModal;
  301. end;
  302.  
  303. procedure SafeShowFormModal;
  304. var v: TVariantArray;
  305. begin
  306. setarraylength(V, 0);
  307. ThreadSafeCall('ShowFormModal', v);
  308. end;
  309.  
  310. procedure AkwardAntiBan;
  311. begin
  312. if AntiBanB = 'True' then
  313. begin
  314. if (not(LoggedIn))then
  315. LoginPlayer;
  316. for R := 300 to 500 do
  317. for RG := 1 to 6 do
  318. case Random(2) of
  319. 0:begin
  320. writeln('anti ban 1');
  321. HoverSkill('Magic', False);
  322. wait(100+ random(R));
  323. HoverSkill('Range', False);
  324. SleepAndMoveMouse(600+random(400));
  325. end;
  326. 1:Begin
  327. writeln('anti ban 2');
  328. Gametab(RG);
  329. wait(R + random (R));
  330. GameTab(7);
  331. end;
  332. 2:begin
  333. writeln('anti ban 3');
  334. PickUpMouse;
  335. wait(R + random (r));
  336. PickUpMouse;
  337. wait(R + random (r));
  338. end;
  339. 3: begin
  340. writeln('anti ban 4');
  341. SayCurrentLevels('Magic');
  342. end;
  343. 4:begin
  344. writeln('anti ban 5');
  345. MakeCompass('S');
  346. Wait(R + random(R));
  347. MakeCompass('N');
  348. Wait(R + random(R));
  349. end;
  350. end;
  351. end else
  352. begin
  353. writeln('what the Hell? you`r not using antiban?!?!?!?');
  354. wait(1000);
  355. writeln('have fun being banned...');
  356. end;
  357. end;
  358.  
  359. procedure sleeps;
  360. begin
  361. if SleepB = 'True' then
  362. begin
  363. If TimeFromMark(SRL_Time) > ((strtoint(SleepT) + Random(10)) * 60000) Then
  364. begin
  365. Writeln('Sleeping...');
  366. Logout;
  367. Wait(((strtoint(SleepF))) * 60000);
  368. LoginPlayer;
  369. SleepN:= SleepN + 1;
  370. ReportVars[2] := ReportVars[2] + 1;
  371. SrlRandomsReport;
  372. SetAngle(True);
  373. end;
  374. end;
  375. end;
  376.  
  377. function findtabs: Boolean;
  378. begin
  379. wait(500);
  380. if (TabExists(4) = true) and (TabExists(7) = true) then
  381. begin
  382. result := true;
  383. writeln('Both tabs where found, going on');
  384. end else
  385. begin
  386. Writeln('One of the tabs does not show up, waiting.');
  387. Result := false;
  388. wait(10000);
  389. if (TabExists(4) = true) and (TabExists(7) = true) then
  390. begin
  391. result := true;
  392. writeln('nevermind! they are up now, going on');
  393. end else
  394. begin
  395. Result := False;
  396. writeln('well, your out of luck, the tabs arent showing up, terminating');
  397. Terminatescript;
  398. end;
  399. end;
  400. end;
  401.  
  402. function findspell(HighAlch: boolean): boolean;
  403. var x, y, HAlchDTM: integer;
  404. begin
  405. HAlchDTM := DTMFromString('78DA63B46662604860644006BFBEF18069982' +
  406. '8A31D504D04AA1A982C5C8D03116A9C816A5209A83102AA4922A0' +
  407. 'C61EA82604BF1A004F1D05B8');
  408. findtabs;
  409. GameTab(7);
  410. wait(500);
  411. if HighAlch = True then
  412. begin
  413. if FindDTM(HAlchDTM, x, y, 559, 336, 583, 360) then
  414. begin
  415. FreeDTM(HAlchDTM);
  416. result := True;
  417. end else
  418. begin
  419. writeln('High Alch was not found, terminating');
  420. Result := False;
  421. Wait(10000);
  422. if FindDTM(HAlchDTM, x, y, 559, 336, 583, 360)then
  423. begin
  424. writeln('never mind, lucky bastard');
  425. FreeDTM(HAlchDTM);
  426. result := True;
  427. end else
  428. begin
  429. writeln('yep, your screwed. terminating');
  430. terminatescript;
  431. end;
  432. end;
  433. end else
  434. begin
  435. if (GetColor(713, 258) = 849658) and (GetColor(720, 254) = 3195184) then
  436. begin
  437. result := True;
  438. end else
  439. begin
  440. writeln('Low Alch was not found, terminating');
  441. Result := False;
  442. Wait(10000);
  443. end;
  444. if (GetColor(713, 258) = 849658) and (GetColor(720, 254) = 3195184) then
  445. begin
  446. writeln('Never Mind! Low Alch was found, going on');
  447. result := True;
  448. end else
  449. begin
  450. writeln('Low Alch was not found, terminating');
  451. Result := False;
  452. end;
  453. end;
  454. end;
  455.  
  456. procedure clickspell;
  457. begin
  458. if findspell(strtobool(AlchB)) then
  459. begin
  460. writeln('changing coords');
  461. mousebox(563, 339, 582, 349, 3);
  462. getmousepos(x, y);
  463. end else
  464. begin
  465. mmouse(717, 253, 6, 6);
  466. GetMousePos(x, y);
  467. end;
  468. if (IsUpText('ast')) then
  469. begin
  470. c := 0;
  471. repeat
  472. begin
  473. findspell(strtobool(AlchB))
  474. writeln('clicked spell #' + inttostr(c));
  475. mouse(x, y, 0, 0, true);
  476. wait(150+ random (200));
  477. mouse(x, y, 0, 0, true);
  478. wait(2200+ random (100));
  479. inc(c);
  480. Counter:=counter+1;
  481. exp:= exp + 65;
  482. ReportVars[0] := ReportVars[0] + 1;
  483. ReportVars[1] := ReportVars[1] + 65;
  484. SrlRandomsReport;
  485. sleeps;
  486. end;
  487. until (c = 100+ random (50));
  488. prog;
  489. AkwardAntiBan;
  490. end;
  491. end;
  492.  
  493.  
  494. procedure alch;
  495. begin
  496. Writeln('starting alching');
  497. repeat
  498. begin
  499. clickspell;
  500. end;
  501. until strtoint(alchs)=counter
  502. end;
  503.  
  504. procedure prog;
  505. begin
  506. writeln(' ');
  507. writeln('Akwardsaw says "Thanks for using my Auto Alcher! Please post your proggy!');
  508. writeln(' ');
  509. writeln('Or, you can pm it to me on villavu.com or email at akardsaw@yahoo.com!"');
  510. writeln('--------------------------------------');
  511. writeln('While running for: ' + TimeRunning);
  512. writeln('And alching: ' + IntToStr(Counter) + ' Things,');
  513. writeln('You have gained a whopping ' + IntToStr(exp) + ' Exp!');
  514. writeln('you have slept ' + InttoStr(SleepN) + ' times');
  515. writeln('--------------------------------------');
  516. writeln(' ');
  517. writeln('Do you have a question? Do you have a concern?');
  518. writeln(' ');
  519. writeln('Or do you just want to tell me how awesome I am?');
  520. writeln(' ');
  521. writeln('Then pm me on the forums, or e-mail me at akardsaw@yahoo.com');
  522. end;
  523.  
  524. Procedure ScriptTerminate;
  525. Begin
  526. prog;
  527. End;
  528.  
  529. procedure MySmartSetup;
  530. begin
  531. if SmartB = 'True' then
  532. begin
  533. writeln('setting up smart');
  534. SMARTSetupEx(100, True, True, False);
  535. SetTargetDC(SMARTGetDC);
  536. end else
  537. begin
  538. writeln('Not using smart eh? well your not too smart your self');
  539. wait(500);
  540. writeln('but then again your using this script, so heres a cookie!');
  541. end;
  542. end;
  543.  
  544. begin
  545. SetUpSRL;
  546. SafeInitForm;
  547. SafeShowFormModal;
  548. SRLID := SrlIdName;
  549. SRLPassword := SrlPass;
  550. ScriptID := '1207';
  551. mousespeed := 7;
  552. MySmartSetup;
  553. DeclarePlayers;
  554. LogInPlayer;
  555. MarkTime(SRL_Time);
  556. alch;
  557. end.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement