SRL Archive - First Scripts

My first script(Cooker)


Lancelot074

2007-08-22 11:30:47


//Made by Lancelot074
program New;
{.include OSi.txt}

const Fire = 3584499; //Change only if needed

Procedure Cook(FishType:integer);
var c,Cooked,RawFish,rawx,rawy,firex,firey,subx,suby:integer;
begin
case FishType of
0:begin RawFish := BitmapFromString(8, 4,
'000001874D23804921834C21874D238D5123975725000001000001' +
'874D23804921874D23905325995928A35E2A000001000001874D23' +
'834C218D5123000001000001000001000000000000000001000001' +
'000001000000000000000000000000'); subx:=20; suby:=20; end;//Lobster
1:begin RawFish := BitmapFromString(4, 4,
'000001B9AEADBFB6B6C6BEBE000001C4BBBACBC4C4D4CECE000001' +
'CDC6C5D6D0D0DAD4D4000000000001000001000001'); subx:=-2; suby:=20; end;//Trout
2:begin RawFish := BitmapFromString(4, 4,
'000001A98B86AE908AB59691000001B2938DBB9A95C1A49E000001' +
'BC9C97C2A5A1C4A9A5000000000001000001000001'); subx:=-2; suby:=20; end;//Salmon
3:begin RawFish := BitmapFromString(5, 2,
'564D42000001CAB7ADA67A5F000001000001DACEC7CFBEB6000001' +
'302020'); subx:=0; suby:=8; end; //Shrimp
end;
while(FindBitmapToleranceIn(RawFish,rawx,rawy,560,210,730,465,50))and(FindColorSpiralTolerance(firex,firey,Fire,5,5,514,337,20))do
begin
Mouse(rawx-subx,rawy-suby,25,25,true);
Mouse(firex,firey,3,3,true);
c:=0;
while(FindBitmapToleranceIn(RawFish,x,y,rawx-10,rawy-10,rawx+10,rawy+10,50))and(c<30)do
begin
c:=c+1;
wait(75+random(25));
end;
Cooked:=Cooked+1;
status('Cooked: '+inttostr(Cooked));
wait(100+random(300));
end;
end;

begin
SetupOSi;
Cook(3);
end.

Well, this is my frist script, it basically cooks fish on a fire.
I know it looks nooby and it nooby but I need some help.
I still need to add multiple players and a banking procedure so I need some help with that if anyone can help. I also need to put in anti randoms and anti ban. All help is appreciated.:spot:

Pwnt by Pwnt

2007-08-30 16:47:15

yeah… not much =\ and im pretty sure you have to have {include SRL/SRL.scar} in there, and SetUpSRL; but I cant really tell because your script is so hard to read =\ my MSN is [email]Pwnt_by_Pwnt@hotmail.com[/email] or PM me :) I can help

Kik

2007-08-30 17:45:39

Very well done for a first script. I'm glad to see a beginner take on something as hard as bitmaps instead of an autotalker (althought autotalkers are a very good way to get accustomed to SCAR). Good use of while loops Keep up the good scripting!

To Pwnt by Pwnt: I know you're trying to help all the new scripters, but try not to post in every single one of the last ten topics. It looks like you're just trying to get your post count up, and in a way it could be considered spam.

Pwnt by Pwnt

2007-08-30 18:50:44

=\ I dont care about post count, I just dont want new scripters to script wrong but think its right, and keep doin it wrong =\ then its hard to learn it the right way…

Lancelot074

2007-09-01 11:06:55

Thanks for the feedback, I'm currently trying to find a good place where you may position this script, such as Rouges Den. So, I'm trying to add bank procedures and multiple players + anti randoms and anti ban. Hopefully I will update the script soon.

HyperSecret

2007-09-01 12:57:55

if you need any help add me on msn or aim whichever and ill help, but nice job on the cook

lordofdapoop

2007-09-03 03:20:21

Looks good. I guess I'll test. It's late and I'm bored. ;-)

kornthebldgd

2007-09-03 16:56:35

whats it cook??

Lancelot074

2007-09-03 19:27:31

It, only cooks 4 fish as of now, it will not long at all to add in some more fish.

bob_the_noob

2007-09-05 07:04:45

gl on fixing the script i need a cooker+banker

ps:need to cook 42000 lobs:(