SRL Archive - RS3 Outdated / Broken Scripts

Wu-Tang Clan Coshing [DirectX Compatible]


Wu-Tang Clan

2014-02-02 13:46:53

I'm tired of having scripts that nobody knows about in my scripts folder. I made this for thieving but don't use it anymore so I thought I'd toss it out here for others.
Setup is pretty easy:
Trap the trainer as shown, but instead of the angle that Limo uses, I just have it work with the angle when you press the compass, so when you log in, click on the compass to get the default North and camera then it should run for a long time. The script is really finicky with colors so you will usually have to use the ACA by yourself to pick the colors of the advanced trainer's scarf.
Have a rubber blackjack equipped and start the script with the trainer trapped like in the picture. If its a big problem, I can do a more in depth tutorial on how to do this.
If you want to run with DirectX then just go to the end of the script and remove the // In front of the Smartplugins call

I give credit where it's due:
http://villavu.com/forum/showthread.php?t=76847&highlight=limo+cosher

program Cosher;
{$Define SMART}
{$I SRL-6/SRL.simba}

// If you are getting "nope" in your debug box, change the curly brackets to a different set of Col,Tol,Hue,Sat or make your own new set.
const
{Col = 4137326;
Tol = 5;
Hue = 0.8;
Sat = 0.20;}

Col = 3415915;
Tol = 6;
Hue = 0.05;
Sat = 0.18;

{Col = 2627188;
Tol = 5;
Hue = 0.05;
Sat = 0.18;}

procedure DeclarePlayers;
// I stole this off some random script... logs you in and stuff.
begin
setLength(players, 1);
currentPlayer := 0;

with players[0] do
begin
loginName := '';
password := '';
isMember := True;
isActive := true;
world := -1;
end;
end;

function FindVolunteer: Boolean;
var
i, h: Integer;
TPA: TPointArray;
ATPA: T2DPointArray;
t: TTimeMarker;
p: Tpoint;
begin

FindColorsTolerance(TPA, Col, MainScreen.GetBounds, Tol, ColorSetting(2, Hue, Sat));
if (Length(TPA) < 1) then
begin
Writeln('nope');
Exit;
end;

ATPA := TPA.ToATPA(20, 20);
SortATPAFromMidPoint(ATPA, Point(randomRange(mainscreen.playerpoint.x - 100, mainscreen.playerpoint.x + 100), mainscreen.playerpoint.y));

h := High(ATPA);

for i := 0 to h do
//writeln(length(atpa[i]));
begin
if (Length(ATPA[i]) < 25) then
Continue;

Mouse(ATPA[i][random(High(ATPA[i]))], MOUSE_MOVE, MOUSE_HUMAN);
if IsMouseOverText(['alk', '-to', 'vance', 'dvance', 'ickpock'], 500) then
begin
//mouse(p, mouse_Right, MOUSE_ACCURATE);
fastclick(mouse_right);
Wait(500);
chooseOption._select(['ure', 'Lure'], MOUSE_LEFT, true, 1.00, 300);
//if (not DidClick(false)) then
begin
t.Start;
Wait(300 + Random(50));
if (t.getTime > 10000) then
begin
Exit;
end;

Wait(RandomRange(1100, 1300));
Exit(True);
end;
end else
Exit;
end;
end;

procedure GoThruChat;
begin
if (conversationBox.areTalking()) then
WriteLn('GoThruChat');
conversationBox.continue(true, true);
Wait(200+Random(100));
conversationBox.continue(true, true);
Wait(500+Random(100));
end;

function KnockKnock: Boolean;
var
i, h: Integer;
TPA: TPointArray;
ATPA: T2DPointArray;
t: TTimeMarker;
begin

FindColorsTolerance(TPA, Col, MainScreen.GetBounds, Tol, ColorSetting(2, Hue, Sat));
if (Length(TPA) < 1) then
begin
Exit;
end;

ATPA := TPA.ToATPA(20, 20);
SortATPAFromMidPoint(ATPA, Point(randomRange(mainscreen.playerpoint.x - 100, mainscreen.playerpoint.x + 100), mainscreen.playerpoint.y));

h := High(ATPA);

for i := 0 to h do
//writeln(length(atpa[i]));
begin
if (Length(ATPA[i]) < 25) then
Continue;

Mouse(ATPA[i][random(High(ATPA[i]))], MOUSE_MOVE, MOUSE_HUMAN);
if IsMouseOverText(['alk', '-to', 'vance', 'dvance', 'ickpock'], 500) then
fastclick(mouse_right);
Wait(500);
chooseOption._select(['nock', '-out'], MOUSE_LEFT, true, 1.00, 300);
begin
//if (not DidClick(false)) then
begin
t.Start;
if (t.getTime > 6000) then
WriteLn('No good');
Exit(True);
end;
end;
end;
end;

procedure TripleLoot;
begin
Wait(200);
mouseBox(inttobox(345,203,399,237), MOUSE_RIGHT);
(chooseOption.select(['oot']));
mouseBox(inttobox(345,203,399,237), MOUSE_RIGHT);
(chooseOption.select(['oot']));
mouseBox(inttobox(345,203,399,237), MOUSE_RIGHT);
(chooseOption.select(['oot']));
conversationBox.continue(true, true);
end;

begin
smartPlugins := ['d3d9.dll']; // Only for DirectX
SetupSRL();
DeclarePlayers;
If Not Players[CurrentPlayer].Login Then
Players[CurrentPlayer].Login;
repeat
FindVolunteer;
Wait(550+Random(100));
GoThruChat;
//Wait(250+Random(250));
KnockKnock;
TripleLoot;
Wait(1000+Random(100));
until (False);
sixHourFix(); // Not tested, probably won't work
end.
If you need any help just hit me up. I can work on it if something is not working, didn't do much testing in DirectX- mostly used it when I had OGL. Great XP too :)

~ Wu-Tang forever dawg.

aliasisthis

2014-02-03 06:01:31

Great, thanks heaps! I've really been looking forward to another coshing script. Will try now and get back to you.

How are you meant to input the colour settings though? .. I got it to work up to knocking him out but it clicks in the wrong spot when it goes to triple loot.

Roko

2014-02-05 13:44:55

I'm glad there's now a thieving script! Only problem is that I can't get it to work properly. I've set it all correctly and it does work for the first Lure->Knockout->Loot->Loot but after that it starts knocking then looting without even luring. I'm wondering what is causing this and I've been trying to change a few lines to make it work after I've found the problem but I cannot fix it. If you could please help me it would be very nice of you. Thanks!

Thief

2014-02-06 06:59:54

When I try to run with direct x, it just continuously tries to loot without clicking 'lure' or 'knockout' first.
I'd try with OpenGl, but recently both my rs client and smart have been crashing when I try to change to OpenGl. :(

tehYosh

2014-02-06 08:13:56

mfw seeing the last post by Thief in the thieving section.

I know you're an SRL member and more than likely know this, but you could just add 'minimap.setAngle(MM_DIRECTION_NORTH);' in your loop after login to make it point north instead of telling people. I would try this but I fortunately maxed thieving a long time ago! Nice to see you posting a few scripts though!

For those having problems with ACA, what I tend to do is try get as many colours as I can on CTS 2 and make sure it doesn't interfere with anything else around it, I then also relog (due to slight colour changes) and do it again a couple of times, hopefully that might make it a bit more stable for you!

Wu-Tang Clan

2014-03-22 12:15:56

Updated script so it now triple loots just about every time :)

lendaz

2014-03-23 17:52:11

From: Wu-Tang Clan
Updated script so it now triple loots just about every time :)


Gratz , is there any fail safe for when disappears?

Wu-Tang Clan

2014-03-23 20:36:25

From: lendaz
Gratz , is there any fail safe for when disappears?


I'm going to fill in the blanks and say that your asking if the trainer disappears?
Well in that case your character will more than likely log out from inactivity, which will shut down the script. So in a way yes there is a failsafe.

Rogue Sniper

2014-07-09 02:10:00

i cant seem to get either version of this to work … can anyone help … im trying to get 6 thieving for the desert treasure quest

EvilCabbage

2014-07-09 03:11:00

From: Rogue Sniper
i cant seem to get either version of this to work … can anyone help … im trying to get 6 thieving for the desert treasure quest


6 Thieving? Okay…

As far as I know you need 52 Thieving so in case you didn't mean that go check out a guide on the quest again to avoid dissapointment

Rogue Sniper

2014-07-09 10:52:09

From: EvilCabbage
6 Thieving? Okay…

As far as I know you need 52 Thieving so in case you didn't mean that go check out a guide on the quest again to avoid dissapointment


wow didnt even reread … ment 66 … but still cant get the bot to do anything

xSorrels

2014-10-13 22:29:59

Sorry for spam.

I know this script was written over 8 months ago, however, still would like to use this.

From start, all it seems to want to do is 'Loot'.

Never trys to Lure or Knockout after updating color constants using ACA.

A little turpy told me it has something to do with the Mainloop; ( TrippleLoot; )

Tried searching around on how to setup Mainloops correctly; ect… No luck.

Any leads, or direction would be nice, or reworked scripts appreciated!

Thanks in advance.

Ashaman88

2014-10-13 22:34:06

confirm outdated?

xSorrels

2014-10-13 22:41:42

From: Ashaman88
confirm outdated?


Oh, no.

Sorry. Was just giving my post a title. Not too sure if its confirmed or not.

My apologies.

Just trying to get this to work. (:

cbrems

2014-10-22 18:29:52

I haven't been able to get this to work :'(

xSorrels

2014-10-28 19:16:28

From: cbrems
I haven't been able to get this to work :'(


Neither have I.

Does anyone have a reworked Coshing script thats up to date/working?

PheteyGee

2014-10-29 01:09:33

This script isn't outdated, and mine works fine. Currently going 2.5hours strong in Direct X mode. I did modify the script a bit so I hope it is ok to post the changes (nothing major and no credits to me… all credit goes to wu-tang for the basis of this script).

Procedure GoThruChat becomes:
procedure GoThruChat;
begin
if (conversationBox.areTalking()) then
WriteLn('GoThruChat');
conversationBox.continue(true, true);
Wait(randomrange(200,450));
conversationBox.continue(true, true);
Wait(randomrange(450,600));
end;

Procedure TripleLoot becomes:
procedure TripleLoot;
var
i: integer;
begin
Wait(200);
mouseBox(inttobox(304,188,326,209), MOUSE_RIGHT);
(chooseOption.select(['oot']));
wait(randomrange(20,70));
mouseBox(inttobox(304,188,326,209), MOUSE_RIGHT);
(chooseOption.select(['oot']));
wait(randomrange(20,70));
mouseBox(inttobox(304,188,326,209), MOUSE_RIGHT);
(chooseOption.select(['oot']));
conversationBox.continue(true, true);
end;

and the final loop becomes:
begin
smartPlugins := ['d3d9.dll']; // Only for DirectX
SetupSRL();
DeclarePlayers;
If Not Players[CurrentPlayer].Login Then
Players[CurrentPlayer].Login;
repeat
FindVolunteer;
Wait(randomrange(500,700));
GoThruChat;
Wait(250+Random(250));
KnockKnock;
TripleLoot;
Wait(randomrange(1800, 2400));
until (False);
sixHourFix(); // Not tested, probably won't work
end.

I only added in a few extra waits, and used ACA to find new colours. Also changed around the inttobox coordinates (because it was clicking the on the black wall).

Edit: I found the biggest problem was it wasn't luring after it had just triple looted. In the mainloop play with the
 wait(randomrange(1800,2400)); 
to find what best suits your computer. If it waits longer it should do the findVolunteer procedure flawlessly
Hope this helps
PheteyGee

3zx

2014-11-03 09:16:20

Thanks for your help Phetey, seems to be working fine for me now :)

PheteyGee

2014-11-03 09:38:25

From: I F A I L
Thanks for your help Phetey, seems to be working fine for me now :)


no worries ;)

iP3RF3CT SA1NTS

2014-11-03 09:42:01

From: PheteyGee
This script isn't outdated, and mine works fine. Currently going 2.5hours strong in Direct X mode. I did modify the script a bit so I hope it is ok to post the changes (nothing major and no credits to me… all credit goes to wu-tang for the basis of this script).

Procedure GoThruChat becomes:
procedure GoThruChat;
begin
if (conversationBox.areTalking()) then
WriteLn('GoThruChat');
conversationBox.continue(true, true);
Wait(randomrange(200,450));
conversationBox.continue(true, true);
Wait(randomrange(450,600));
end;

Procedure TripleLoot becomes:
procedure TripleLoot;
var
i: integer;
begin
Wait(200);
mouseBox(inttobox(304,188,326,209), MOUSE_RIGHT);
(chooseOption.select(['oot']));
wait(randomrange(20,70));
mouseBox(inttobox(304,188,326,209), MOUSE_RIGHT);
(chooseOption.select(['oot']));
wait(randomrange(20,70));
mouseBox(inttobox(304,188,326,209), MOUSE_RIGHT);
(chooseOption.select(['oot']));
conversationBox.continue(true, true);
end;

and the final loop becomes:
begin
smartPlugins := ['d3d9.dll']; // Only for DirectX
SetupSRL();
DeclarePlayers;
If Not Players[CurrentPlayer].Login Then
Players[CurrentPlayer].Login;
repeat
FindVolunteer;
Wait(randomrange(500,700));
GoThruChat;
Wait(250+Random(250));
KnockKnock;
TripleLoot;
Wait(randomrange(1800, 2400));
until (False);
sixHourFix(); // Not tested, probably won't work
end.

I only added in a few extra waits, and used ACA to find new colours. Also changed around the inttobox coordinates (because it was clicking the on the black wall).

Edit: I found the biggest problem was it wasn't luring after it had just triple looted. In the mainloop play with the
 wait(randomrange(1800,2400)); 
to find what best suits your computer. If it waits longer it should do the findVolunteer procedure flawlessly
Hope this helps
PheteyGee


Thank you very much boss, i'll try this out!

PheteyGee

2014-11-03 18:54:29

PM me XPGSaints, I'll send you the fully updated script with antiban and progress report if it doesn't work…

The Mayor

2014-11-03 20:21:04

From: PheteyGee
PM me XPGSaints, I'll send you the fully updated script with antiban and progress report if it doesn't work…


If you've got a working version then it might be best to just release it. I don't think Wu-Tang is going to update this so you might as well report this thread and get it moved to the outdated section, and then release a working version (give credits ofc ;))

PheteyGee

2014-11-03 21:38:11

From: The Mayor
If you've got a working version then it might be best to just release it. I don't think Wu-Tang is going to update this so you might as well report this thread and get it moved to the outdated section, and then release a working version (give credits ofc ;))


Then that would mean I would have to release it before I won the 250m scripting comp… :P. Not that I think i have any chance of winning cause I don't believe it's a original concept…

The Mayor

2014-11-03 22:14:08

From: PheteyGee
Then that would mean I would have to release it before I won the 250m scripting comp… :P. Not that I think i have any chance of winning cause I don't believe it's a original concept…


Oh didn't realise that script was this script :p Just 1 week to go and you can release it :D

PheteyGee

2014-11-04 00:12:44

Haha. Planning on doing a big script release all at once. Including an Advanced barb (when I fix a few bugs). Pretty keen to give more back to the community :)

Extravz

2014-11-09 07:54:59

Need help. It says successfully executed and nothing is running. Script stops right after. Any solution?

WeAreSG

2014-11-11 13:19:07

It doesn't lure and just starts looting ): Can't seem to get it to work even after updating it with the parts from PheteyGee

PheteyGee

2014-11-13 03:00:25

From: WeAreSG
It doesn't lure and just starts looting ): Can't seem to get it to work even after updating it with the parts from PheteyGee


Check the other script I posted. Does that one work for you?

masterBB

2014-11-13 13:00:08

moved to outdated