SRL Archive - First Scripts

My very first script *proud* :D


Pure1993

2008-01-27 15:41:58

I worked all day to piece this one together. It doesn't have much use, but it is the very first one never the less, and I am dam proud of it! :spot:
I tried to use the official standards, I hope it is somewhat like it should be.

//Well, all you really need to do is log in, and be able to use home tele
//which means that your timer istn't still on, if you can't use
//it for a while, just stand in the little courtyard of the lumbridge caste
//between the two fountains.
//I hope you enjoy this script (well, there is not much to enjoy, seeing
//that it is pointless, but I guess it is a polite thing to say ^^)
//BTW: I'd love it if you could just copy paste your debug box,
//so I can see if it works for everyone ^^

program LumbridgeToDraynor;
{.include SRL/SRL.scar}
{.include SRL/SRL/Skill/Magic.scar}

var
x,y: integer;

procedure Signature;
begin
Writeln('________ ________ ___ ')
Writeln('| ______| | _ \ | |')
Writeln('| | | | \ | \_|')
Writeln('| |_____ _____ | |__| |')
Writeln(' _____ | |_____|| ____/ _______ ')
Writeln(' | | | | | ___|')
Writeln('_____| | | | |___ |')
Writeln('|______| |__| |_____|')
Writeln(' -Lumbrdigde To Draynor Runner')
Wait(3000);
end;

begin
Mousespeed := 13;
ClearDebug;
Signature;
Cast('Home Teleport');
wait(20000);
SymbolAccuracy := 50;
MakeCompass('N');
SetRun(true);
RoadColor := FindRoadColor;
begin
if RadialWalk(RoadColor,25,10,68,1,1) then
begin
wait(7000);
Flag;
Writeln('Successful walk #1');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,300,360,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #2');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,300,370,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #3');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,300,370,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #4');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,270,320,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #5');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,270,340,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #6');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,180,360,72,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #7');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,270,330,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #8');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,250,290,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #9');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,250,285,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #10');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,170,220,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #11');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,170,190,70,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #12');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,170,190,60,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #13');
end;
RoadColor := FindRoadColor;
if RadialWalk(RoadColor,200,250,50,1,1) then
begin
wait(3000);
Flag;
Writeln('Successful walk #14');
Writeln('woohoo! It worked! :D');
end;
end;
end.

Now, I was going to try to make it go into the wizzard tower and create a rune mystery runner, but I just can't figure out doors, help is always appreciated. ;)

EDIT: Oh, I just realized I forgot to post the people to whom I owe thanks for creating tuts so even someone as myself can learn this within 24 hours, well, here they are:

-WhoCares357 for his unbelieveably good beginners guide.:spot:
-ZephyrsFury for his awsome tut on mapwalking. :spot:
-JAD who got me out of many frustrating momments with his error solving Tut ;)
-Toterache for his (good but a bit confusing) tut on some of the basic Mouse procedures. :)

Rikje

2008-01-27 15:58:37

Nice done :)

- After a radial walk. don't add a wait of 3secs. just 1 sec.
- Nice Standaards :)
- make you're mainloop just to call the head procedures. so the walking have his owne :p

Gl ;)

Ghiik

2008-01-27 16:05:39

[admin]Dear User,
Your post count has been reset on account of your mass of spam posts. Please take the time to read this thread before posting again.
Sticky: Attention Spammers and Leechers...
RAM

Cheers,
SRL-Forums.[/admin]

Hi, all. I'm new here and just trying familiarize myself with others. Personally I don't know how to script what-so-ever. But I am willing to be a tester. Soo, with that being said, laterz.:garfield:

Hey everyone.. just wanna wish you all a happy new years. Turned 17 today.. hooray. Best Regards, Ghiik.:spot:

Could someone please exlpain exactly how SRL works?

Thanks man. Ill have to read up some more. :)

Very nice looks good.

Not too shabby + rep

Pretty good. 2 thumbs up.

I like it.

I have been getting those essences.

NOt to bad good job for your first.

Pure1993

2008-01-27 16:06:35

thanks for the comment rikjes :D
The wait time is there on purpose, because it happens now and then that the flag disappears for a second when having to go a step back or around the corner, and that messes up the entire script, and with the wait function, it is supposed to stop the program form thinking that we are already there. ^^
I'll go form the big loop into a procedure tomorrow, I'm a bit tired after all that reading and scripting, I will only make mistakes today. lol :D
Edit: thank you, too, for the comment ghiik. :)
Edit 2: boah, I just got scarred, thought that scamming thing was directed at me… well, good thing that it is unusual to get heart attacks at my age. ;)

Psychor

2008-01-27 16:11:29

Nice job on your first script, and way better standards then i ever used.

- Yep, i had those flag problems also, same solution.
- It's better to replace Flag with FFlag(0) it does the same, but has beter failsafes

Pure1993

2008-01-27 16:21:55

Thanks psychor, i just added it to my to do list for this week, problem is my student internship starts tomorrow, and I have no clue how much time i will have, but I suppose this won't take too long.
Well, going to bed now, will check this thread tomorrow, but don't let that stop you guys from posting comment (btw, I would really like to see someone post their debug box. The script shouldn't take more than 3 minutes… so if anyone would mind… :D)

Faelstorm

2008-01-29 10:52:42

Nice first script! I have problems with doing mapwalking, so im a little jealous ^^

Pure1993

2008-01-29 14:46:23

Haha, no need for jealousy, I have just written a huge tut for beginners, covering everything from the meaning of "begin"s and "ned"s up to using colors and and mouse movements. Now I am working on one for intermedians for mapwalking, dtms, autocoloring, and a few neat SRL functions. I'll send you a link once I get done, will puplish both at once. ^^
Btw: thanks a lot for your post (would almost have forgotten to say that :D)

dillbagz

2008-01-30 03:58:56

i just can't get over how quickly you picked this stuff up i think this means a true scripter in the making gratz on your first post

Friends forever. :D

your true friend
Dillbagz

Ruroken

2008-01-30 07:03:55

:rolleyes: standards are overrated.

MY first script was a coords based tut runner, guess how well that one worked out…:p

Sir R. M8gic1an

2008-01-30 09:28:45

nice first script :) just with this one you've done more walking than i ever have :p Anyway it's good that you learnt walking so fast, now remember that people are Craaaaazyyy about failsafes. we want perfect walks :) we want DDTMs, more possibilities of walking, blind click as last resort, etc :)

eg.

if not RadialWalk(RoadColor,25,10,68,1,1) then
if not RadialWalk(RoadColor,27,13,70,3,3) then
if not RadialWalk(RoadColor,29,16,72,5,5) then
if not FindSymbol('furnace') then
Mouse(50, 94, 3, 3, True);
FFlag(0);


~RM

gerauchert

2008-01-30 09:46:12

couldnt have quite put that better myself… :)

Another tip, would to be to make a symbol searching function that will decrease the accuracy over a certain time peroid incase there is a white, red, or yellow dot on the symbol. Just a good failsafe to add in ;)

Gratz and keep up the good work

Pure1993

2008-01-30 10:17:53

Wow, I nenver expected so many positive replies. I mean, i was pretty certain it was a good script, taking into account how much determination i put into it, but still, wow. I'd really like to thank everyone for their comments, and how to improve it, I will get to it when I get a chance, I already have an idea for a final failsafe in case all else fails, but it will have to wait, I just wrote a huge beginners tut which I will publish once I get done with my intermedians guide, so it will be a huge double opening. After that I plan to make a team script with dillbagz, probably an easy rune mystries runner to start out with, and later a power miner or essence miner.
You guys won't believe how happy I am about all these comments. :)