You need to put the include underneath your program name, not at the very top:
Code:
Program New;
{.Include Srl/Srl.scar}
Begin//Main Loop
End.
Also you made the procedure to load a bitmap but you never actually loaded it in your mainloop. If you only want to call the procedure FBitmap in your mainloop then you need to call LoadBitmap inside of FBitmap, before you tell the script to find your bitmap. If you don't load the bitmap into the variable Pickaxe1 then Pickaxe1 won't have the value of your bitmap and you won't be able to find it as a result.
Here is how you should call your bitmap:
Code:
Program New;
var
pickaxe1: integer;
procedure loadbitmap;
begin
pickaxe1 := BitmapFromString(29, 30, 'beNpjYCAOMOrJs5oos1lr' +
'sDvosAO5DKQBRlzI2j/COSrFMzEnILscyDVQUCDeQCNnL1zIzDPQN' +
'ijaMTwxtKieOGMRBuo7uONCalIswEAAOtg+JA7mBXzAxM0PiDCN1b' +
'VxhiM5EWZg2AIRxFigs4GIkOGMBBHQqWjGWvqEQEIbj8nAgMKFgLr' +
'gTkUzFhjaQARkQCKRxOSBcCoQwd0PMRYSekASyI2p7iDaZHQzkX0B' +
'QZBYABoODBOiEx7CWLiZaEEHNx/oZlgiIdmpeKIGYjgwYRMymRHT+' +
'/jdATEcr0qEU4EMUnIrA16VJDuVvATAQAVAW6dSz0yEU0mNqQF0Kn' +
'Vjaug4FWEsdZ0KCQFghUVdp0KMpapTGSCVC1XTKsJYIKK2sVDDqRo' +
'CaOX8YAUAtihtew==');
end;
procedure FBitmap;
Var
x, y :integer;
begin
LoadBitmap;//Either call to load it here
FindBitmapToleranceIn(pickaxe1, x, y, 676, 714, 391, 429, 25);
end;
begin//Or load it in your Main Loop
LoadBitmap;
FBitmap;
end.
Also don't forget to free your images, DTMs or BMPs after your use them so they don't eat up your memory:
Code:
FreeBitmap(Pickaxe1);