PDA

View Full Version : Grimy Wergali Cleaner [SoulSplit]



g ked
07-25-2013, 06:16 AM
Redone whole thing, been running for 5 hours now. Should work aye ok!

SETUP:
Darkest Setting
Stand somewhere near Fernahei in Neitzinot
Play in 'Lite' mode
Face South at the highest angle you can

Edit: Should work now.



program FckHerb;
{$i srl/srl.simba}
var
X, Y, Add, UnHerb, DropWergali, CloseTrade, BuyX, Redweed, Falesafe: Integer;



Procedure Fernahei;
var
tmpCTS, l, r:Integer;
ObjectTPA:TPointArray;
begin
MouseSpeed:=15;
tmpCTS := GetToleranceSpeed;
SetColorToleranceSpeed(2);
SetToleranceSpeed2Modifiers(0.13, 0.50);
if FindColorsTolerance(ObjectTPA, 209744, 8, 25, 518, 359, 2) then
begin
SetColorToleranceSpeed(tmpCTS);
SetToleranceSpeed2Modifiers(0.02, 0.02);
L := High(ObjectTPA);
mmouse((ObjectTPA[r].x), (ObjectTPA[r].y), 2, 2);
wait(randomrange(100, 150));
clickmouse2(mouse_left);
Writeln('Attempted to click Fernahei');
wait(randomrange(2000, 2500));
end;

begin;
repeat
if FindDTM(RedWeed, x, y, 70, 60, 398, 110)=false then
Fernahei;
until FindDTM(RedWeed, x, y, 70, 60, 398, 110)
Writeln('Trading Fernahei');
end;
end;

Procedure Buy;
begin
begin
if FindDTM(RedWeed, x, y, 70, 61, 407, 110) then
mmouse(x, y, 1, 1);
wait(randomrange(100, 200));
clickmouse2(mouse_right);
wait(randomrange(400, 600));
end;

begin
if FindBitmapToleranceIn(BuyX, X, Y, 1, 1, 510, 335, 10) then
begin
mmouse(x, y,1,1);
wait(250);
ClickMouse(X, Y, mouse_Left)
wait (randomrange (1000, 1200));
end;
end;

begin;
TypeSend('69');
wait (randomrange (400, 666));
end;

begin
if FindBitmapToleranceIn(Closetrade, X, Y, 1, 1, 510, 335, 10) then
begin
mmouse(x, y,1,1);
wait(250);
ClickMouse(X, Y, mouse_Left)
wait (randomrange (1000, 1200));
end;
end;

end;

Procedure Clean;
begin


begin
repeat
if FindDTM(RedWeed, x, y, 522, 172, 762, 500) then
mmouse(x, y, 1, 1);
wait(randomrange(100, 200));
clickmouse2(mouse_left);
wait(randomrange(450, 500));
until FindDTM(RedWeed, x, y, 522, 172, 762, 500)=false
end;

begin
repeat
if FindDTM(RedWeed, x, y, 522, 172, 762, 500) then
mmouse(x, y, 1, 1);
wait(randomrange(100, 200));
clickmouse2(mouse_left);
wait(randomrange(450, 500));
until FindDTM(RedWeed, x, y, 522, 172, 762, 500)=false
end;

begin
movemouse (659, 186);
wait (400);
clickmouse (659, 186, mouse_left);
end;
end;

Procedure Drop;
begin

if FindBitmapToleranceIn(falesafe, X, Y, 404, 156, 760, 501, 10) then
begin
movemouse(653, 187);
wait(250);
ClickMouse(X, Y, mouse_Left)
end;

if FindDTM(unHerb, x, y, 522, 172, 762, 500) then
begin
mmouse(x, y, 1, 1);
wait(randomrange(100, 150));
clickmouse2(mouse_right);
wait(randomrange(300, 310));
end;

if FindBitmapToleranceIn(DropWergali, X, Y, 404, 156, 760, 501, 10) then
begin
mmouse(x, y,1,1);
wait(250);
ClickMouse(X, Y, mouse_Left)



begin
repeat
if FindDTM(unHerb, x, y, 522, 172, 762, 500) then
drop;
until FindDTM(unHerb, x, y, 522, 172, 762, 500)=false
end;

end;
end;

Procedure All;
begin
repeat
fernahei;
buy;
clean;
drop;
inc (add);
until (add=500); //right here is where you change how many times you want the bot to buy and clean them
end;

begin
SetupSRL;
MouseSpeed := 15;
FaleSafe := BitmapFromString(94, 27, 'meJztV1FKxEAMHVTYqiiyIIJb/B' +
'X1GH55AW/Wu+wJ9lwuDBuyb5I0ztS2I1PeR5q+SV4ymdIO+8N29wI' +
'Y9odB8s8J0OCRNK3sY6j7p2dATJH65wRo8EhKOSWFHBfebh8B MSBB' +
'e/RbP3+k8YFg3+bFNFaB34gAkkpsrWoPJzudf5VYbHf3AIiEcptu R' +
'afIFzl5qcsLubq5BkRCuW3HJKTkNE5e6vJCLjcdGRPaHB6Otg T4/t' +
'Ql4vkOjrYatjvdHYNs8LWxEbU5w/rFa/yLblMdov6/zqJt1pphj9l' +
'UWHwA2sxUNzO7t/cGEZ9f3w0i+tePhoYM0PfPnOkWr9qpM4Qwm2DK' +
'uHjtHpFRJxmtM4uIrL0z/P9LdMLRG+X/j87wU8brojJFf2DXaJBKO' +
'9Mn46EVC34t+Ch5bfDPjF2g0Rne24o6Qzq54eyAf2b4EauoM/352w' +
'P0a6cpLdD/xq6oM/3pSwbUhvOLO1Mb+P4g68QPS/EA+g==');
CloseTrade := BitmapFromString(13, 8, 'meJx9jzEKACAMA/MmdVWcRH/Vpys' +
'NlGLFkiE0NyQARKT0dXQMAPqnmEYst0n5p8dE74+xBrTPH/OGWJxg' +
'qTfPCdaNGPSuyebJpDo2R5xMRA==');
BuyX := BitmapFromString(126, 12, 'meJzdls0NwjAMhRmkdw4swYhcu' +
'ksn6FpQYckytt+L26YqUPlgpfFPvjhOxmm+vL9xmhcZrredIn 4Wh0' +
'53cn88F5HQou8P/bWii3WgmpS2wVeH0afFLiPptL+Rs8gXM+Fpn06' +
'vF3ldTlqftvNUdAQfVbJmIooFqyN20PqxE1Jbvl/EBEWvD/LJ7oCP' +
'WZ9HvbrYw+1uNmvA9XlNW2nHv2qS2lor0uiISTElNJOMu5qvE 95Av' +
'tJt0PLJ36isJS/Lr5gXU0qPJPHWnbztM6jsK+TTyb3IEz6kwnlKac' +
'33Iu/qmZPn56LeJerkUcml5O0tE7mhCi+Sr+joBUhehraeN5N3lNY' +
'WGCKv6SHy4sSGi5BVEHmyxfVu4z7rHI1Hwk6sCTInIVAmTo9K JINC' +
'u3AoJb4KtMVND5xJUzq+/48QTv7nAumNyZ/r59IePk/0oYH2kH8Bm' +
'N1xiA==');
DropWergali := BitmapFromString(120, 10, 'meJzdlkESwjAIRTmIexdewiO66' +
'V16gl5LMzLDUAI/JDXVMcOCEAw/ryTjsm5EdLnelnUrVpyP2/3xLE' +
'bvUabiSHxG0W9ZdKhlz3nGqaPSf8+ZfcCZfdPhbhDEeznzVGs DcR0' +
'0+SYHT4eDOFkOJZcXc9ZpMtVIo3gvZ/22aOU4zksRavc7ZsrpV25M' +
'WFc/S61oFfjDnHGfA1Bgfz5sppyBfESY8ZPEzuGcaafmd3HvtUsDl' +
'Ms3Q1LYCZz1DcJXjNTI93yTs6DoKjcmAHAGr7GWDTLreIQaNI/psa' +
'gt85x5SZerkZpy7laugF5htB+yuUusztR4AWTz86gKFmPikV8 Xdf3' +
'Mtiaz/gpHhHXZvH/dP2jg4jTtBY9fq7I=');
RedWeed := DTMFromString('mWAAAAHicY2FgYHBgYmBwAWIPILYHYg5GBg YWIOYCYl4gDpWVBmMDJS4Gex1eBk6gHmTMiIZBAAC7rgNV');
UnHerb := DTMFromString('mWAAAAHicY2FgYPBgYmBwBGInIHYD4qdAsR dA/ASIXwKxl5Q4g6+0BEOgjBRDgo4GAztQDBkzomEQAACdFAcO');
all;
freebitmap (DropWergali);
freebitmap (BuyX);
freebitmap (falesafe);
freebitmap (closetrade);
freedtm (UnHerb);
freedtm (RedWeed);
end.

Kevin
07-25-2013, 07:05 PM
You may wanna change the name of that script in your code as swearing is against forum rules.

g ked
07-26-2013, 06:45 AM
Fixed it ;) and changed the cursing.

Sax
07-26-2013, 03:25 PM
RIP Standards :D

euphemism
07-26-2013, 03:31 PM
Why do you call the SetupSRL() procedure at the end of the main block? This means SRL is never setup properly. If using SRL, SetupSRL() should always be the first procedure called in your main block.

g ked
07-26-2013, 09:39 PM
Why do you call the SetupSRL() procedure at the end of the main block? This means SRL is never setup properly. If using SRL, SetupSRL() should always be the first procedure called in your main block.

Well I am new to scripting, but will remember that from now on thanks to you!

rj
07-26-2013, 09:42 PM
You should declare the variables all in one swipe too like this:

var
Add, UnHerb, DropWergali, TimeToClean, BuyX, RedWeed, Falesafe: Integer;

g ked
07-26-2013, 09:59 PM
You should declare the variables all in one swipe too like this:

var
Add, UnHerb, DropWergali, TimeToClean, BuyX, RedWeed, Falesafe: Integer;

Can i do that with X, Y: Integer; aswell?

BigRedJapan
07-26-2013, 10:02 PM
Yes you Just add!


X, Y, Add, UnHerb, DropWergali, TimeToClean, BuyX, RedWeed, Falesafe: Integer;

call the X, Y, and the rest of the Var

g ked
07-26-2013, 10:48 PM
Got it ;) thanks!

g ked
07-27-2013, 05:10 AM
Any more tips on making this bot even better?

Hoodz
07-27-2013, 03:23 PM
Any more tips on making this bot even better?

I made a inlog function and a check if you are logged in our out. I can give you that :) I upload my Soulsplit PowerFighter, PowerThiefer, PowerMiner and PowerFisher tomorrow, All flawless and i have with every script a 15+ hours proggy.

g ked
07-27-2013, 04:21 PM
I made a inlog function and a check if you are logged in our out. I can give you that :) I upload my Soulsplit PowerFighter, PowerThiefer, PowerMiner and PowerFisher tomorrow, All flawless and i have with every script a 15+ hours proggy.

Mind letting me use it :)?

Hoodz
07-27-2013, 09:45 PM
Mind letting me use it :)?

Maybe we can write a small soulsplit include with functions like is_logged_in/login and maybe some text recognising.

rj
07-27-2013, 11:36 PM
Maybe we can write a small soulsplit include with functions like is_logged_in/login and maybe some text recognising.


Don't mean to hi-jack this thread but you guys may find this useful:

Extract SSUpchars to C:simba/fonts extract SSinclude to C:/simba/includes

Tested on 667 mode with max brightness, but I have not tested the SPS since the old client

test:

{$i srl/srl.simba}
{$i SSInclude/SSInclude.simba}
Begin
SetupSSInclude;
ActivateClient;
Wait(400);
WriteLn(SS_GetUpText);
End.

I'm missing "q" from the font set but that's alright
have fun

g ked
07-28-2013, 03:05 AM
Don't mean to hi-jack this thread but you guys may find this useful:

Extract SSUpchars to C:simba/fonts extract SSinclude to C:/simba/includes

Tested on 667 mode with max brightness, but I have not tested the SPS since the old client

test:

{$i srl/srl.simba}
{$i SSInclude/SSInclude.simba}
Begin
SetupSSInclude;
ActivateClient;
Wait(400);
WriteLn(SS_GetUpText);
End.

I'm missing "q" from the font set but that's alright
have fun

Ahhh text recognition, but whats the other do?

rj
07-28-2013, 03:14 AM
Ahhh text recognition, but whats the other do?

SPS? That's walking

g ked
07-28-2013, 04:00 AM
SPS? That's walking

Like I said, quite new to making bots

rj
07-28-2013, 04:05 AM
Like I said, quite new to making bots

Here: http://villavu.com/forum/showthread.php?t=71461&highlight=sps+walking+guide

g ked
07-28-2013, 04:46 AM
Here: http://villavu.com/forum/showthread.php?t=71461&highlight=sps+walking+guide

I tried to do this but the maps are different.. Is that my problem?
I wish I could add you on skype? Do you happen to have one.

Hoodz
07-28-2013, 08:39 AM
Don't mean to hi-jack this thread but you guys may find this useful:

Extract SSUpchars to C:simba/fonts extract SSinclude to C:/simba/includes

Tested on 667 mode with max brightness, but I have not tested the SPS since the old client

test:

{$i srl/srl.simba}
{$i SSInclude/SSInclude.simba}
Begin
SetupSSInclude;
ActivateClient;
Wait(400);
WriteLn(SS_GetUpText);
End.

I'm missing "q" from the font set but that's alright
have fun

Ooh i didnt know there was already a ss include. Thanks

Hoodz
07-28-2013, 09:06 PM
log in function and isloggedin function.


var
x, y, count: integer;

//////////////////////////////////////////////////////////////////////

const

USERNAME = '';
PASSWORD = '';

///////////////////////////////////////////////////////////////////////

function IsLoggedIn: boolean;
begin
if findcolortolerance(x, y, 1448008, 494, 451, 611, 522, 15) then
begin
result := true
end
else
begin
writeln('we are logged out!')
writeln('logging back in...')
result := false
end;
end;

procedure LoggingIn;
begin
Wait(200);
movemouse(659, 313);
writeln('entering username');
Wait(200);
clickmouse(x, y, mouse_left);
count := 0;
repeat
Inc(count);
PressKey(VK_Back);
until count > 25;
Wait(250);
sendkeys(USERNAME, 0, 0);
Wait(1000);
writeln('entering password');
movemouse(665, 365);
Wait(200);
clickmouse(x, y, Mouse_left);
Wait(200);
count := 0;
repeat
PressKey(VK_Back);
Inc(count);
until count > 25
sendkeys(PASSWORD, 50, 25);
writeln('logging in');
Wait(1000);
movemouse(576, 396);
Wait(1000);
ClickMouse(x, y, mouse_left);
Wait(8000);
writeln('logged in! (?)')
end;


example in my powerfisher (flawless):


program SSPowerFisher;

{$I srl/srl.simba}

var
x, y, LobsterDTM, count, fishhour, xpgain, xphour: integer;
pbox: tbox;

const

USERNAME = '';
PASSWORD = '';

function IsLoggedIn: boolean;
begin
if findcolortolerance(x, y, 1448008, 494, 451, 611, 522, 15) then
begin
result := true
end
else
begin
writeln('we are logged out!')
writeln('logging back in...')
result := false
end;
end;

procedure LoggingIn;
begin
Wait(200);
movemouse(659, 313);
writeln('entering username');
Wait(200);
clickmouse(x, y, mouse_left);
count := 0;
repeat
Inc(count);
PressKey(VK_Back);
until count > 25;
Wait(250);
sendkeys(USERNAME, 0, 0);
Wait(1000);
writeln('entering password');
movemouse(665, 365);
Wait(200);
clickmouse(x, y, Mouse_left);
Wait(200);
count := 0;
repeat
PressKey(VK_Back);
Inc(count);
until count > 25
sendkeys(PASSWORD, 50, 25);
writeln('logging in');
Wait(1000);
movemouse(576, 396);
Wait(1000);
ClickMouse(x, y, mouse_left);
Wait(8000);
writeln('logged in! (?)')
end;

procedure setmeup;
begin
writeln('setting up....');
writeln('putting angle right');
sleep(3000)
count := 0
repeat
inc(count);
presskey(40);
until count > 25;
sleep(1000);
writeln('completed');
writeln('open inventory');
movemouse(747, 172);
sleep(200);
clickmouse(x, y, mouse_left);
sleep(1000);
writeln('completed');
writeln('set up completed!');
end;

procedure DropFish;
begin
LobsterDTM := DTMFromString('mlwAAAHicY2dgYBBkgAAeIBYGYjEglgRidi DmA2J+IBYCYhkgFoCq5QTiGG2QLCNWzM+AG2DXAcFQAACfVgGD ');
if finddtm(LobsterDTM, x, y, 565, 123, 935, 565) then
begin
mouse(x, y, 0, 0, mouse_right)
sleep(100)
mouse(x, y+40, 0, 0, mouse_left)
freedtm(LobsterDTM);
sleep(350)
inc(count)
exit;
end
else
begin
freedtm(LobsterDTM);
sleep(150)
exit;
end
end;

procedure Gofishing;
Var
TPAA: T2DPointArray;
TPA: TPointArray;
CTS, I: Integer;
Begin
CTS := GetColorToleranceSpeed;
ColorToleranceSpeed(2);
setcolorspeed2modifiers(0.13, 1.34);
FindColorsSpiralTolerance(344, 230, TPA, 9732725, 309, 212, 364, 238, 5);
ColorToleranceSpeed(CTS);
TPAA := TPAToATPAEx(TPA, 3, 1);
SortATPASize(TPAA, True);
For I := 0 To High(TPAA) Do
If GetArraylength(TPAA[i]) > 2 Then
Begin
MiddleTPAEx(TPAA[i], x, y);
MMouse(X, Y, 3, 3);
clickmouse(x, y, mouse_left)
sleep(200)
dropfish;
exit;
end
else
begin
exit;
end;
end;

procedure IsFishing;
begin
pbox := IntToBox(309, 104, 383, 211)
if pixelshift(pbox, 500) < 600 then
begin
GoFishing;
end
else
begin
DropFish;
end
end;

procedure proggy;
begin
cleardebug;
fishhour := Round((count)/(GetTimeRunning/3600000.0));
xpgain := round((count)* 360);
xphour := round((xpgain)/(gettimerunning/3600000.0));
writeln('Time Running: '+ MsToTime(GetTimeRunning,3))
writeln('fishes catched: ' + inttostr(count))
writeln('fishes per hour: ' + inttostr(fishhour))
writeln('xp gained: ' + inttostr(xpgain))
writeln('xp per hour: ' + inttostr(xphour))
exit;
end;

begin
cleardebug;
setupsrl();
writeln('Hoodz SSPowerFisher V1');
repeat
if (not isloggedin) then
begin
loggingin;
SetMeUp;
end;
if (isloggedin) then
begin
IsFishing;
proggy;
end;
until(false)
end.

rj
07-28-2013, 09:11 PM
^^ is logged in could be turned into 1 line:

function ss_loggedin():Boolean;
begin
Result := (GetColor(426, 492) = 16777215);
end;

The text is the same color always, and the function is false by defualt

Hoodz
07-28-2013, 10:25 PM
^^ is logged in could be turned into 1 line:

function ss_loggedin():Boolean;
begin
Result := (GetColor(426, 492) = 16777215);
end;

The text is the same color always, and the function is false by defualt
Oh thanks, but it works good so i dont change it. For what are you exactly looking for?
I search for the report button.

rj
07-28-2013, 10:37 PM
Oh thanks, but it works good so i dont change it. For what are you exactly looking for?
I search for the report button.

white color on the report button

Hoodz
07-28-2013, 10:40 PM
white color on the report button

Thanks barbrady

jamesb96
05-10-2014, 07:02 PM
it starts up okay clicks on the guy and it opens the shop then just does nothing :/ dont know whether or not this has anything to do with it:
The following DTMs were not freed: [2, 3]
The following bitmaps were not freed: [5, 6, 7, 8]