PDA

View Full Version : SoulSplit/Torva Auto-Buyer



C130s
04-30-2014, 02:33 AM
This is my very first attempt at Pascal scripting so be kind please! I didn't see one of these on here already and it didn't require any walking so it was good for my first attempt. I'm currently using it to buy Dragonstone so I'll try to add something that will automatically cut the dragonstone and turn them into bolt tips if anyone wants to help me with that!

It is a basic auto-buyer using colors and the "Buy 10" bitmap. All you have to do is replace the "ItemColor=" with the color you want the bot to click on.

*NOTE*
It seems to bug out sometimes and not let you press "F2" to stop the script so only carry the money you are willing to spend or it might got overboard on you.

Source:

//Simba Autobuyer Script
//Author: SSYN/C130s
program AutoBuyer;

var
x,y: Integer;
Bmp: Integer;

const
ItemColor= 7277398;

procedure LoadBmps;
begin
Bmp := BitmapFromString(15, 7, 'meJxzD4l1D4n9DwYMDAzuqFwgiUc' +
'WUzGEJKgYYizxiiEi+BWjuQTCgLORAZp6uEqIIAMGgKtHEwEA 9Cah' +
'cA==');
end;

procedure RightClickItem;
begin
if(FindColor(x,y,ItemColor,27,24,501,320)) then
begin
MoveMouse(x,y+random(3));
Wait(100);
ClickMouse(x,y,mouse_Right);
Wait(100);
end;
end;

procedure LeftClickItem;
begin
if(FindBitmap(Bmp,x,y)) then
begin
MoveMouse(x,y+random(3));
Wait(100);
ClickMouse(x,y,mouse_Left);
end;
end;

procedure FreeBmps;
begin
FreeBitmap(Bmp);
end;

begin
repeat
LoadBmps;
RightClickItem;
LeftClickItem;
FreeBmps;
until(false);
end.