SRL Archive - RS3 Outdated / Broken Scripts

Mcht


Shuttleu

2008-04-12 19:05:08

Compatable with SCAR v3.15 and SRL rev#15

{-------------------------------------------------------------------------------]
[ __ __ ___ _ _ ________ ]
[ | \ / |/ _ \| | | |___ ___| ]
[ | \/ | / \_| |__| | | | ]
[ | |\ /| | | _| __ | | | ]
[ | | \/ | | \_/ | | | | | | ]
[ |_| |_|\___/|_| |_| |_| ]
[ Master Crafter Hide Tanner V2.6 ]
[ by shuttleu ]
[ ]
[===============================================================================]
[ ]
[ NAME : MCHT (Master Crafter Hide tanner) ]
[ AUTHOR : shuttleu ]
[ CATEGORY : Crafting ]
[ DESCRIPTION : Tans hides in al-kharid. ]
[ MEMBERS ONLY : No ]
[ MULTIPLAYER : Yes ]
[ SCAR VERSION : 3.15 ]
[ SRL VERSION : 4 #rev 15 ]
[ RELEASE DATE : 12/04/2008 ]
[ ]
[===============================================================================]
[ ]
[ 01. Use the offcial runescape client (or SMART), with low detail and very ]
[ bright. Set your screen resolution to 32bit true colour. ]
[ 02. Setup lines 45 to 55 (or more thean 55 if you have more than one player. ]
[ 03. Put money in first bank slot and cowhide in anyother slot as long as it ]
[ is at the top ]
[ 03. Position your runescape characters in the bank at al-kharid ]
[ 04. Drag the crosshair over the runescape client and press play. ]
[ 05. Enjoy the script and please post progress/feedback :D ]
[ ]
[-------------------------------------------------------------------------------}

Well i have been working on updating this script for the last few days and its finally ready (thank god)

PROGGYS

Sadly there is no proogy built in yet sooo… there will be none till i have added them in
the longest 3 proggys will be posted here:




KNOWN BUGS

none known at the moment

script


there are three versions of the script

the first one (MCHT.scar) is just the normal script where you have to use a internet browser like IE or firefox

the second (MCHT SMART.scar) one is for normal smart

and the third one (MCHT modified SMART.scar) is for the people who have modified their srl like in this post http://www.villavu.com/forum/showthread.php?t=21279

and remember to post any bugs and proggys

HISTORY


MCHT.scar (27.7 KB 1 views)
MCHT SMART.scar (28.0 KB 1 views)
MCHT modified SMART.scar (27.7 KB 0 views)
MCHT v2.scar (27.7 KB, 3 views)
MCHT SMART v2.scar (28.0 KB, 4 views)
MCHT modified SMART v2.scar (27.7 KB, 1 views)


NEXT VERSION


Proggy


~shut

v8godfather

2008-04-12 20:11:34

Well I went to test this out and realized that its a hide tanner :confused:

[ NAME : Lumbridge Castle Flax Spinner (LumbCFS) ]
[ AUTHOR : Vilon ]
[ CATEGORY : Crafting ]
[ DESCRIPTION : Spins flax into bowstrings, at Lumbridge.

kingarabian

2008-04-13 04:32:18

From: v8godfather
Well I went to test this out and realized that its a hide tanner :confused:


Mines almost done. I started it a year ago. Nearly finished it though and then quit it >.<.

Shuttleu

2008-04-13 04:35:14

From: v8godfather
Well I went to test this out and realized that its a hide tanner :confused:

oh yeh… sorry i forgot to change that bit :duh:
changed it now

Expect a update within the next few days :)

~shut

Shuttleu

2008-04-14 17:49:18

UPDATE


updated to v2

added SRL stats
added better walking
added break

~shut

the scar noob

2008-04-16 11:09:31

Nice script you've got there, but there are still some things that could be improved or that are wrong.

Don't take this badly, because you're on a good road;)

Also plz note, that the information underneeth is constructive criticism.

–let me edit this post–

Shuttleu

2008-04-16 13:43:44

From: the scar noob
Nice script you've got there, but there are still some things that could be improved or that are wrong.

Don't take this badly, because you're on a good road;)

Also plz note, that the information underneeth is constructive criticism.

–let me edit this post–

well this is my first script which i have written entirely from scratch

and what do you mean by

Also plz note, that the information underneeth is constructive criticism.

there isn't even anything underneath

~shut

Shuttleu

2008-04-20 13:59:51

update


updated to v2.5

added autocolor to walking

~shut

the scar noob

2008-04-21 14:34:16

From: shuttleu
well this is my first script which i have written entirely from scratch

and what do you mean by


there isn't even anything underneath

~shut


Yes, yes, my appologies, I forgot to edit the post and give feedback, let's begin, shall we?;)

function AutoFurnaceSymb: Integer;
Is made with ACA v.2.

function AutoBankSymb: Integer;
Is made with ACA v.2.

function FindObjCustom1(var cx, cy: Integer; Text: TStringArray; Color: TIntegerArray; Tolerance: Integer): Boolean;
A function from the SRL folder.

function ShopScren : Boolean;

Tip:
Make a new variable, an integer, and load the shop ddtm in that variable.

*You don't load the shop ddtm, if this fucntion is being called multiple times (which happens), SCAR will have a big memory leak and your script will stop functioning.

*Do the above (the tip)and after usage of the ddtm (thus at the end of your funciton), free it.

procedure Banking;

I want you to have a look at this:

repeat
FindNormalRandoms;
FindObjCustom1(x, y, ['ank', 'oot'], [737364, 670799], 30)
Writeln('found bank');
MMouse(x, y, 1, 1);
Wait(500 +random(500));
Mouse(x, y ,1, 1, false);
ChooseOption('ickly');
Wait(2000 +random(1000));
until Bankscreen or Pinscreen;

First of all, it'll check for randoms, secondly it'll try to find the bank booth and here it get's wrong..

Even if the bank booth hasn't been found, it'll still output that the bank is found and do the mouse actions.

Let's think about it: the bank booth isn't found, the funciton will:

*output a message in the SCAR Debug Box that the bank booth has been found
*Move the mouse and click the mouse at x, y coordinates, which are the coordinates from an object found in a previous procedure/function (you use x and y in other object finding procedure's/functions aswell, so the x and y will hold the coordinates found of the previous object finding..).

This will have a result of: weird mouse movements, which isn't humanly at all (it'll also right click, which makes it more detectable).

The even bigger problem that I see in that procedure, is that you have an infinite loop

until Bankscreen or Pinscreen;

What do you have to do to avoid this?
Add a variable and increase it every time you try to find the bankbooth and repeat that all until the bank/pin screen is popped-up or when your maximum tries has been reached (then put player false, etc..).
You can use other methods like using a timer;)

Further in the procedure:
if Players[currentplayer].strings[0]= 'soft' then
begin
Withdraw(1, 1, 27);
end;
if Players[currentplayer].strings[0]= 'hard' then
begin
Withdraw(1, 1, 81);
end;
*plz make a case statement for this
*why don't you load your ddtms for withdrawing, then you're sure that you've withdrawed the correct objectives

if not(FindDTM(WhichDDTM('hide'), x, y, MSX1, MSY1, MSX2, MSY2)) then
begin
CloseBank;
Error('withdrawing cowhides', 'No cowhides left in the bank');
NextPlayer(false);
end;
if FindDTM(WhichDDTM('hide') ,x, y, MSX1, MSY1, MSX2, MSY2) then
begin
repeat
MMouse(x, y, 1, 1);
Wait(500 +random(500));
Mouse(x, y, 2, 2, false);
Wait(500 +random(500));
ChooseOption('Withdraw All');
Wait(1000 +random(1000));
until FindDTM(WhichDDTM('hide'), x, y, MIX1, MIY1, MIX2, MIY2);
end;

*To begin with, make from this a "if-then-begin-end-else-begin-end" statement instead of just "if-then-begin-end" 2 times:)
*Againt, load your ddtm in a variable and don't forget to free it, because you didn't free'd it over here aswell

procedure WalkToTanner;

*I see that you don't understand the "RadialWalk" function properly.
function RadialWalk(TheColor: Integer; StartRadial, EndRadial: Integer; Radius: Integer; Xmod, Ymod: Integer): Boolean;

You use it like this:

if RadialWalk(cactuscol , 10, 100, 70, x, y) then
*you have a range of 90 between your begin- and endradial, try to use a max range of 70 (optional)
*you have 70 radius, that the very end of your minimap, be sure you wont have trouble
*
Xmod, Ymod: Integer

This doesn't mean the x and y coordinate.. it's a randomize number, you can compare it with the randomazation of MMouse –> MMouse(fx, fy, 1, 1).

However, try to use "RadiaWalkEx", where you can use a tolerance etc;)
NOTE: RadialWalkEx doesn't already clicks, you'll need to move your mouse and click when using that:)

Tip: Make function from this, which returns a boolean, so that you can see if you've walked to the tanner succesfully.

procedure WalkToBank;

Same comments as "WalkToTanner".

    if Players[currentplayer].strings[0] = 'soft' then
begin
ReportVars[1] := ReportVars[1] + CountItemsDtm('inv', WhichDDTM('soft'));
end;
if Players[currentplayer].strings[0] = 'hard' then
begin
ReportVars[2] := ReportVars[2] + CountItemsDtm('inv', WhichDDTM('hard'));
end;

*Put this in a case statement
*Again, load your ddtm's in a var and free them after usage
*ReportVars glitch, you'll update your stats, while you don't know if you've reached the bank or not

procedure TanHides;
Again some problems like in other object finding procedures (like banking).

*
if FindObjCustom1(x, y, ['alk', 'llis'], [4944848, 4680900], 30) then
> problem already stated somewere else above: make it an if statement, infinite loop problem, etc..

Your mainloop:
Your mainloop isn't set up properly, check some tut, if I've got to explain this I'm not done by tomorow:)

Generally notes:

* I see you could've declared some variables local instead of global, do so,
it improves script run.
* Have more failsafes, those are really needed. The best script around have many failsafes,
so that better script run is guaranteed!


Generally hint:

* If there occurs a problem, log out your player andexit out of the current procedure/function.
* Put at every procedure and function "if not(LoggedIn) then Exit;"
* In your mainloop, when you switch players (which should be the only place were you switch players) use "NextPlayer(LoggedIn);"

Why should I do this? What does this do?

Well, if this is used correctly, you do the following:
There occurs a problem, your player gets logout and you exit out of the current procedure/function.
It wont do another procedure or function because you're logged out and you have "if not(LoggedIn) then Exit;' at the very beginning of every procedure/function.
You'll get to the end of your repeat and your script will do "Nextplayer(LoggedIn)", you're not logged in, so you'll put the current player's status to falseand go on with the next one;)

Conclusion:

I think you've put a lot of work into this, but we have to see the facts, my friend.
The better things aren't made by you, the things you made by yourself need some fixing and you make a lot of "beginner" mistakes such as inproperly use of if-statements and no (d)dtm free'ing.

Still nice work dude:) I hope to see more of you in future, keep it up!

-Tsn.

P.S. the things mentioned above are ment to be contructive criticism, don't blame me or this will be the last time I give you feedback.

Shuttleu

2008-04-21 15:47:52

ok well thank you TSN
i will get started on them
then if i sort them out do you think it will be good enough to apply for srl members

btw i used the aca to help me because i couldnt get the autocoloring to work and i took the FindObjCustom from srl rev 14 because i dont like the way it works in srl rev 15

~shut

the scar noob

2008-04-22 11:21:44

From: shuttleu
ok well thank you TSN
i will get started on them
then if i sort them out do you think it will be good enough to apply for srl members

btw i used the aca to help me because i couldnt get the autocoloring to work and i took the FindObjCustom from srl rev 14 because i dont like the way it works in srl rev 15

~shut


Aight:) And I'm glad that you've read my pig post above, I spent rather a lot of time on it:p

-Tsn.

Zezi

2008-04-23 19:01:41

From: the scar noob
Yes, yes, my appologies, I forgot to edit the post and give feedback, let's begin, shall we?;)

function AutoFurnaceSymb: Integer;
Is made with ACA v.2.
[DELETED]
Conclusion:

Still nice work dude:) I hope to see more of you in future, keep it up!

-Tsn.

P.S. the things mentioned above are ment to be contructive criticism, don't blame me or this will be the last time I give you feedback.


Deleted most of things to stop it spamming

But woah, nice one taking the time to look at the script in such great detail!
+rep for being so kind and generous :)

I didn't even pick up on the fact that it'll writeln bank being found, even though it hasn't. I was so silly! XDD
:spot:

the scar noob

2008-04-24 11:27:11

From: boxcrop
Deleted most of things to stop it spamming

But woah, nice one taking the time to look at the script in such great detail!
+rep for being so kind and generous :)

I didn't even pick up on the fact that it'll writeln bank being found, even though it hasn't. I was so silly! XDD
:spot:


Wow! Thank you very much:)

-Tsn.

Shuttleu

2008-05-10 07:25:21

update

fixed a few memory leeks and added a few more failsafes

~shut

lilmike

2008-05-13 13:51:25

first few bugs:

It'll first select in the bank when withdrawing the cow hides the 'withdrawal x' where it will enter 81 after that it'll 'withdraw all', and than it walks away, to the cactus but it doesn't find the furnace symbol, and the auto colour doesn't work with it either.

if you already put a load cash + hides it'll first go to the bank bank the cash and only withdraw the cowhides with withdrawal cowhides X and than withdraw all…. This is very buggy?

Shuttleu

2008-05-16 17:30:46

if your using the normal vversion then i forgot to change it and i will do so now

~shut

XRaye

2008-05-20 20:09:16

Sweet, I'll try it once i get my player set up with all the right stuff.

Shuttleu

2008-05-21 09:45:05

as a few people have said before it is buggy
i only really made this script to get into members
i didnt really test it that well but i will probably fix it in a few days

~shut

trentuno30

2008-09-08 05:37:23

Line 848: [Error] (16977:34): Unknown identifier 'CountItemsDtm' in script


plz help!!

Simtoon

2008-09-08 16:54:38

last post 05-21-2008 this script is 3 months old