SRL Archive - Help and Support

Can Some one Check This for Me


JiveTonto@Gmail.com

2006-04-26 20:22:49

Hi since you all hate me i decided to do some scripting (With the little knoledge i know)
and i had like 8k yew shorts i needed to sell fomr when i was bower leveling so i thought why not make a genral store seller so i went and made on.
I dont knwo mcuh so i need some one to check and i only knwo the old stuff
program GeneralStoreSeller JiveTonto@Gmail.com;
{.include osi.txt}
var he,heh: integer;
var bitmap: integer;

///////Start at any general store and have the item in NOTES
//////Notes in first inv slot
//////General store window open

Procedure LoadBmps;
begin
bitmap := BitmapFromString(15, 7,
'5D54475D54475D54475D54475D54475D54475D54475D54475D5447' +
'5D54475D54475D54475D54475D54475D54475D54475D5447FFFFFF' +
'FFFFFF5D54475D54475D54475D54475D5447FFFFFFFFFFFFFFFFFF' +
'5D54475D54475D54475D5447FFFFFFFFFFFFFFFFFF0000005D5447' +
'5D54475D5447FFFFFFFFFFFF000000FFFFFFFFFFFF5D54475D5447' +
'FFFFFFFFFFFFFFFFFFFFFFFF0000005D54475D5447FFFFFFFFFFFF' +
'0000000000005D5447FFFFFFFFFFFF5D54475D5447000000FFFFFF' +
'FFFFFF0000005D54475D5447FFFFFFFFFFFF0000005D54475D5447' +
'FFFFFFFFFFFF0000005D54475D5447FFFFFFFFFFFF0000005D5447' +
'5D5447FFFFFFFFFFFF0000005D54475D5447FFFFFFFFFFFF000000' +
'5D54475D5447FFFFFFFFFFFF0000005D54475D5447FFFFFFFFFFFF' +
'0000005D54475D5447FFFFFFFFFFFF000000');
end;

procedure seller;
begin
FindColorTolerance(he,heh,7839919,572,218,598,239,100)
mouse(he,heh,15,15,false)
sleep(100+random(300))
FindBitmap(bitmap,x,y)
mouse(x,y,15,15,true)
end;

begin
loadbmps;
repeat
seller;
until(1>2);
end.

Bow Cutter Needs to be srlised
{Bow Cutter, JiveTonto@Gmail.Com

Start in any bank
Have logs in first bank slot
Kife in first inventory slot
Do setup below!
}
program BowCutter;
{.include si.scar}

const
BowToMake = 5000;//Number of logs you want to be made into bows
CutType = 3;//1. Shafts 2.Short Bow 3.Long Bow
AccountSet = 1;//Account set from Si
NormalLogs = false;//are you cutting plain old logs?

var cutx,cuty:integer;
BowsMade,sst,cst,wst,wet,awt,srt,tih,tim,tis:integer;

procedure ProgReport;
begin
Writeln('----===Bow Cutter By JiveTonto@Gmail.Com===----');
Writeln('------=====Progress Report=====-------');
cst:=getsystemTime;
srt:=(cst-sst)/1000;
tih:=srt/3600;
tim:=(srt/60)-tih*60;
tis:=srt-tim*60-tih*3600;
awt:=wet-wst;
Writeln('Worked for '+inttostr(tih)+' Hours '+inttostr(tim)+' Minutes '+inttostr(tis)+' Seconds');
Writeln('Average Time Cutting Logs '+inttostr(awt/1000)+' Seconds');
Writeln('Fletched '+inttostr(BowsMade)+' Bows');
Writeln('Making Approximately '+inttostr(BowsMade/(srt/60))+' Bows Per Minute');
Writeln('Making Approximately '+inttostr((BowsMade/(srt/60))*60)+' Bows Per Hour');
Writeln('------=====Progress Report=====-------');
end;

procedure SetCutCoords;
begin
if(cuttype = 1)then begin cutx:=106; cuty:=406; end;
if(NormalLogs)then
begin
if(cuttype = 2)then begin cutx:=260; cuty:=406; end;
if(cuttype = 3)then begin cutx:=413; cuty:=406; end;
end else
begin
if(cuttype = 2)then begin cutx:=144; cuty:=406; end;
if(cuttype = 3)then begin cutx:=375; cuty:=406; end;
end;
end;

procedure Bank;
begin
Openbank;
DepositArea(564,257,734,458);
DepositArea(610,215,734,458);
Withdraw(1,1,28);
CloseWindow;
end;

Function AllCut:boolean;
begin
if(GetColor(708,443)=3885652)then
result:=true;
end;

Procedure CutLogs;
var AntiFucked:integer;
begin
UseItem(1);
UseItem(28);
repeat
wait(350);
antifucked:=antifucked+1;
until(getcolor(255,369)=128)or(antifucked>=35)
antifucked:=0;
wait(450);
Mouse(cutx,cuty,4,4,false);
ClickText('X',9,343,528,498);
repeat
wait(350);
antifucked:=antifucked+1;
until(getcolor(255,409)=8388608)or(antifucked>=35)
Speak('27');
wait(1500);
repeat
wait(500);
until(AllCut)or(CheckRandoms(AccountSet,'fletching','N',true,false,[rtAttack, rtBox, rtLamp, rtLeveled, rtLogout, rtText]))
end;

begin
LoadInclude('Fletching Guide',true);
SetCutCoords;
ChatsOff;
sst:=getsystemtime;
repeat
Bank;
wst:=getsystemtime;
repeat
CutLogs;
until(AllCut)
wet:=getsystemtime;
BowsMade:=BowsMade+27;
ProgReport;
until(BowsMade>=(BowToMake-27))
end.

phantombmx

2006-04-26 21:34:42

here it is with srl.. not much that i changed.. just look through the manual a bit (it is includes>srl>SRL Manual… you will have to browse through using like windoes explorer or my computer :D you will learn, but decent to start.. smaller bitmap too.. try makin it 20 by 2

program GeneralStoreSeller; //JiveTonto@Gmail.com
{.include SRL\SRL.scar}
var bitmap: integer;

///////Start at any general store and have the item in NOTES
//////Notes in first inv slot
//////General store window open

procedure LoadBmps;
begin
bitmap := BitmapFromString(15, 7,
'5D54475D54475D54475D54475D54475D54475D54475D54475D5447' +
'5D54475D54475D54475D54475D54475D54475D54475D5447FFFFFF' +
'FFFFFF5D54475D54475D54475D54475D5447FFFFFFFFFFFFFFFFFF' +
'5D54475D54475D54475D5447FFFFFFFFFFFFFFFFFF0000005D5447' +
'5D54475D5447FFFFFFFFFFFF000000FFFFFFFFFFFF5D54475D5447' +
'FFFFFFFFFFFFFFFFFFFFFFFF0000005D54475D5447FFFFFFFFFFFF' +
'0000000000005D5447FFFFFFFFFFFF5D54475D5447000000FFFFFF' +
'FFFFFF0000005D54475D5447FFFFFFFFFFFF0000005D54475D5447' +
'FFFFFFFFFFFF0000005D54475D5447FFFFFFFFFFFF0000005D5447' +
'5D5447FFFFFFFFFFFF0000005D54475D5447FFFFFFFFFFFF000000' +
'5D54475D5447FFFFFFFFFFFF0000005D54475D5447FFFFFFFFFFFF' +
'0000005D54475D5447FFFFFFFFFFFF000000');
end;

procedure Sell;
begin
if(FindColorTolerance(x,y,7839919,572,218,598,239,100))then
Mouse(x,y,5,5,false)
SleepAndMoveMouse(100+random(500))
if(FindBitmap(bitmap,x,y))then
Mouse(x+5,y+2,5,2,true)
SleepAndMoveMouse(100+random(500))
end;

begin
LoadBmps;
repeat
Sell;
until(not(LoggedIn));
end.

JiveTonto@Gmail.com

2006-04-26 21:36:32

ok thanx so every thign was right and i did not fudge up?

phantombmx

2006-04-26 21:40:46

just the if findbitmap then stuff.. you need it to find the bitmap before you use the mouse ;)

JiveTonto@Gmail.com

2006-05-11 05:02:43

ok thanx (told ya i dont know much and wat i do know is as old as fudge)