ub3r |<1||3r*1337*
2006-04-16 22:58:55
ok. i have created my al-kharid script with autocolorfinding kind of, and i keep getting this error!
here is my script
[Offtopic] am i posting too many threads in the help section?[/Offtopic]
Line 124: [Error] (10900:1): Type mismatch in script C:\Program Files\SCAR 2.03\Scripts\al-kharid silk buyer.scarhere is my script
program silkbuyer;
///////////////////////////////////////////////////////////////////////////
///this will buy silk and bank them, improvements can be PMed to me on
///villavu.com/forums made by: ub3r l<1ll3r
///////////////////////////////////////////////////////////////////////////
{Instructions!!!
1. start at the most northern open bank
2. money in first slot
3. V-bright
4. put your pin in Line 127 if you have one
{.Include SRL\SRL.scar}
{version info:
V1:very unstable[unreleased]
V1.9:a lot more stable with double clicking[unreleased]
V1.95: tested and being released
V2: more stable and with symbol to symbol
V3: fixed up a lot of walking, much more faster
V4:will now log off after 20 loads and has anti-randoms and will do this 6 times until the script will end (100 loads)
V5: now with a progress report
V6: Now standardized (i think)
V7: properly standardized and has Mouse flag detection
V8: now with auto color}
var
N:string;
H,poop,Rx,Ry:Integer;
///////////////SETUP////////////////////////////
Const
User = 'killerkoo4'; ////////your username must go here//////////
Pass = ''; ////////your password must go here//////////
////////Thats all folks!////////////////////////////
////////////////////////////////////////////////////////////////
procedure movesilk;
begin
writeln ('facing north and going to the silk buyer!');
Face(N)
if (findcolortolerance(x,y,994407,643,51,677,70,8)) then
Mouse(x,y,1,1,True)else
writeln('color(s) not found! restart script!');
Flag;
if (findcolortolerance(x,y,598088,653,30,697,54,8)) then
Mouse(x,y,1,1,True)else
Writeln('color(s) not found! restart script!');
Flag;
if (findcolortolerance(x,y,2818305,678,34,719,90,8)) then
Mouse(x,y,1,1,true)else
writeln('color(s) not found! restart script!');
Flag;
if (findcolortolerance(x,y,5505420,597,26,709,118,8)) then
Mouse(x,y,1,1,True)else
writeln('color(s) not found! restart script!');
Flag;
wait(3000)
end;
procedure buy;
begin
poop:=0
repeat
if (findcolortolerance(x,y,12425379,4,4,514,336,8)) then
Mouse(x,y,0,0,True)
Mouse(x,y,0,0,True)
wait(3000)
MMouse(224,444,1,0)
wait(800)
Mouse(224,444,1,0,True)
Mouse(224,444,1,0,True)
wait(1000)
MMouse(270,395,1,0)
wait(800)
Mouse(270,395,1,0,True)
Mouse(270,395,1,0,True)
wait(1000)
MMouse(203,448,1,0)
wait(800)
Mouse(203,448,1,0,True)
Mouse(203,448,1,0,True)
wait(1000)
MMouse(280,446,1,0)
Mouse(280,446,1,0,True)
Mouse(280,446,1,0,True)
wait(2000)
MMouse(238,432,1,0)
Mouse(238,432,1,0,True)
Mouse(238,432,1,0,True)
wait(1000)
MMouse(217,445,1,0)
Mouse(217,445,1,0,True)
wait(1000)
MMouse(290,447,1,0)
Mouse(290,447,1,0,True)
Mouse(290,447,1,0,True)
poop:=poop+1
writeln('we have '+IntToStr(poop)+' silk(s) for this load!')
TalkToRand;
wait(2000)
Until(findcolortolerance(x,y,8625060,703,434,724,454,8))
end;
procedure goback;
begin
Face(N)
wait(1000)
if (findcolortolerance(x,y,598088,596,90,656,129,8)) then
Mouse(x,y,1,1,True)
Flag;
if (findcolortolerance (x,y,2818305,610,80,654,133,8)) then
Mouse(x,y,1,1,True)
Flag;
if (findcolortolerance (x,y,598088,594,90,636,129,8)) then
Mouse(x,y,1,1,True)
Flag;
if (findcolortolerance(x,y,994407,594,84,649,106,8)) then
Mouse(x,y,1,1,True)
Flag;
if (findcolortolerance(x,y,bankcolor,587,59,641,99,8)) then
Mouse(x,y,1,1,True)
Flag;
OpenBank;
if (findcolortolerance(x,y,660059,46,111,97,164,7)) then
InPin(5946)
Deposit2(5,27)
wait(5000)
end;
procedure login;
begin
mouse(450,286,10,10,True)
wait(1000)
sendkeys(User)
sendkeys(chr(13))
sendkeys(Pass)
wait(1000)
mouse(298,323,10,10,True)
wait(5000)
mouse(495,341,10,10,True)
end;
Begin
SetupSRL;
if (findcolortolerance(x,y,5918541,397,288,429,303,6)) then
Login;
repeat
movesilk;
buy;
goback;
H:=H+1
Until(H>=20)
loginplayer;
repeat
H:=0
movesilk;
buy;
goback;
H:=H+1
Until(H>=20)
loginplayer;
repeat
H:=0
movesilk;
buy;
goback;
H:=H+1
Until(H>=20)
loginplayer;
repeat
H:=0
movesilk;
buy;
goback;
H:=H+1
Until(H>=20)
loginplayer;
repeat
H:=0
movesilk;
buy;
goback;
H:=H+1
Until(H>=20)
End.[Offtopic] am i posting too many threads in the help section?[/Offtopic]