SRL Archive - RS3 Outdated / Broken Scripts

PiePcAirRuneBuyer!


Ilikepie1995

2007-06-15 15:46:54

My third script.
What script does?Buys air runes at pc rune shop then banks them.Duh.
Version 0.1!

program PiePcAirRuneBuyer;
{.include SRL/SRL.scar}
//Start in Pest Control bank have your money in your first inv.Spot.
//Face North, Highest angle.
//Stand at the very western bank booth.
//The script will keep on buying airs until it would be stoped by the user.
const
Player0 = 0;

Procedure DeclarePlayers;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;
{///////////////////Set up your player//////////////////////}
Players[0].Name := '';// your user name
Players[0].Pass := '';//your password
Players[0].Nick := '';// your nick name
Players[0].Active := True;

end;
Procedure Bank;
var
x, y, fs, fs2 : Integer;
begin

repeat
Flag;
if (FindObj(x, y, 'booth', 607324, 10)) then
Mouse(x, y, 4, 4, False)
else
if (FindObj3(x, y, 'booth', 7243412, 10)) then
Mouse(x, y, 4, 4, False)
else
if (FindObj3(x, y, 'booth', 6324369, 10)) then
Mouse(x, y, 4, 4, False);
Wait(250+random(20));
if (ClickOption('quickly', 1)) then
begin
Flag;
repeat
Wait(100+random(20));
fs := fs + 1;
until (BankScreen) or (fs >= 50);
end;
fs2 := fs2 + 1;
until (BankScreen) or (fs2 > 5);
end;

Procedure LetsDebug;
begin
WriteLn(' Running Time: ' + (TimeRunning) + '')
end;

Procedure GoToRuneShop;
begin
if FindColor(x,y,2497522,520,90,524,94)then
Mouse(x,y,1,1,true);
Wait(7000);
FindColor(x,y,7444935,0,0,500,500);
Wait(500);
Mouse(x,y,1,1,false);
Wait(1000);
ChooseOption(x,y,'e s');
Wait(1000);
end;

Procedure Buying100Airs;
begin
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(487,40,2,2,true);
end;

Procedure GoBackToBank;
begin
if FindColor(x,y,982782,674,83,680,95)then
Mouse(x,y,2,2,true);
Wait(8000);
end;

Procedure DepositAirs;
begin
Mouse(626,229,3,3,false);
Wait(1000);
ChooseOption(x,y,'all');
Wait(1000);
Mouse(487,41,2,2,true);
end;

Function FindFastRandoms: Boolean; //By WT-Fakawi.
var
i: Integer;
begin
for i := 1 to 8 do
begin
case I of
1: if FindDead then
Result := True;
2: if FindMod then
Result := True;
3: if FindMime then
Result := True;
4: if FindMaze then
Result := True;
5: if FindQuiz then
Result := True;
6: if FindDemon then
Result := True;
7: begin
if NoGameTab then
begin
Result := True;
Players[CurrentPlayer].loc := 'No GameTab';
Logout;
Exit;
end;
end;
7: begin
if InBlack then
begin
Result := True;
Players[CurrentPlayer].loc := 'InBlack';
Logout;
Exit;
end;
end;
8: RC;
end;
wait(1);
end;
end;

///////////////////////////////////////////////////////////////////////////

procedure FindRandoms;
begin
FindFastRandoms;
FindNormalRandoms;
end;

begin
SetupSRL;
declareplayers;
CurrentPlayer:= Player0;
activateclient;
loginplayer;
repeat
GoToRuneShop;
Buying100Airs;
FindRandoms;
GoBackToBank;
Bank;
DepositAirs;
until(false);
end.


Scripts made by me.

PieShafter.Version 0.1. 100%Done!
PieStringer.Version 0.1. 100%Done!
PiePcAirRuneBuyer.Version 0.1. 100%Done!

Currently working on.

PieChestThiever.Version 0.1. 0%Done!

3Garrett3

2007-06-15 16:52:04

you know you can attach the file at the bottom right? Do that next time :)


Procedure Buying100Airs;
begin
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(187,85,3,3,false);
Wait(1000);
ChooseOption(x,y,'10');
Wait(1000);
Mouse(487,40,2,2,true);
end;

Wow, really detectible. Here is a semi fix.


repeat
Mouse(187,85,5,5,false);
Wait(500 + Random(500));
ChooseOption(x,y,'10');
i:= i + 10
until(i =>100)
Wait(Random(1000));
Mouse(487,40,2,2,true);

It would be alot better, notice how i used random wait times, it helps it be more sneaky. :)


Procedure GoToRuneShop;
begin
if FindColor(x,y,2497522,520,90,524,94)then
Mouse(x,y,1,1,true);
Wait(7000);
FindColor(x,y,7444935,0,0,500,500);
Wait(500);
Mouse(x,y,1,1,false);
Wait(1000);
ChooseOption(x,y,'e s');
Wait(1000);
end;

Wow, you used FindColor. For walking. Try learning radialwalk. If your going to use findcolor, Use FindColorTolerance. It works the same, but you use a tolerance at the end. 5 Would probably be a good tolerance. But, still try to learn radialwalk.

Try using findcolortolerance or findcolorspiraltolerance for most things. It is ALOT better than using coords. They are really detectable.


Procedure GoToRuneShop;
begin
if FindColor(x,y,2497522,520,90,524,94)then
Mouse(x,y,1,1,true);
Wait(7000);
FindColor(x,y,7444935,0,0,500,500);
Wait(500);
Mouse(x,y,1,1,false);
Wait(1000);
ChooseOption(x,y,'e s');
Wait(1000);
end;

Here, in your if,then statements, you need a begin and end;


Procedure GoToRuneShop;
begin
if FindColor(x,y,2497522,520,90,524,94)then
begin
Mouse(x,y,1,1,true);
Wait(7000);
[b] if [/b]FindColor(x,y,7444935,0,0,500,500) [b]then[/b]
begin
Wait(500);
Mouse(x,y,1,1,false);
Wait(1000);
ChooseOption(x,y,'e s');
Wait(1000);
end;
end;
end;

You forgot to use an if then thing in there too. You need to use if, then, because then, it will only move the mouse or whatever, if it finds the color, or will only use antiban, if the setting is true.

These are a few things to work on. Learn Standards too, i think you copied that bank procedure, because it had good standards, and it used findobj, when you were using findcolor. Take all of this as constructive critisicm(sp?), do not take it offensively(sp again?). I hope this helps.

Pwnt by Pwnt

2007-06-15 19:25:58

yeah same thing as garrett said, add waits and learn radial walk and maybe have a proggy, make it see how many airs are left, how much cash you have, and maybe let the user choose how many to buy ( for later versions ) but otherwise seems pretty good :)

Ilikepie1995

2007-06-15 22:48:26

:P

3Garrett3

2007-06-16 07:46:16

that was a waste of post. Pure spam. We give you advice and all you can say is :p? At least say thanks, i will add that next update, or something. :)

Pwnt by Pwnt

2007-06-16 18:03:51

yeah that was a dumb post.. and garrett let him figure this out? cuz hes not learnin anything if you do it for him..

3Garrett3

2007-06-16 20:06:15

well, i told him why he needed to change it :) :p. I liked it when people gave me examples of what I did wrong, it made me get better.