SRL Archive - Outdated / Broken

[ #36 ] RM Amazon Destroyer !


Sir R. M8gic1an

2009-07-21 03:04:23

RM Amazon Destroyer


Features :
  • Power Cuts ALL f2p Trees
  • Humanlike drop (SRL's new DropPattern)
  • Accurate Tree Detecting


Bugs :

  • May sometimes lose track of tree, but one of the other failsafes will stop you from looking bottish

No proggies to show atm, i'll leave it overnight.

I don't promise any updates for this, the only thing i'll say is that this is problably the base for the Re-Make of RM Extreme Cutter.

If you know how to, and feel like it, go ahead and add locations to the script, but keep it for private use. The Man has permission to add locations and release, with propper crediting.

So, use and abuse i guess! I've watched it run for a while, and I must say i'm rather proud, although it doesn't have many girlish features such as anti-ban :p

It is NOT ADVISABLE to use this script for autoing, it is here just for learning purposes. I have not yet tested it extensiely, and therefore there might still be some minor bugs to iron out.

~RM

Da 0wner

2009-07-21 03:11:30

 if not FindTree(which, x, y) then
begin
writeln('could find tree?');
Result := false;
exit;
end;
Could find tree? or Could not find tree. :p.

Dynamite

2009-07-21 03:15:49

This is a great script ;)

T~M

Naike

2009-07-21 03:17:13

You pretty beast <3

Such flow ^^

Simtoon

2009-07-21 03:44:26

I guess i will use this on my army when there mining hits 60+ :)

EvilChicken!

2009-07-21 05:47:37

From: Simtoon
I guess i will use this on my army when there mining hits 60+ :)


Mining?
QFT.


This looks promising RM. I don't have SCAR on this computer now, I'll get it sometime soon and check this out.
I won't promise to use it, as we both know how that'll end ..
But, good job, keep the flow of nice scrips going.

P1nky

2009-07-21 06:25:31

haha wow RM now for sure no one will use my power chopper as it is kinda ignored, nah jp :( lol

BTW nice code straight up gj dude.

senrath

2009-07-21 06:28:16

Y'know, for a guy who's supposed to be gone until September, you sure are making a lot of scripts.

ZaSz

2009-07-21 07:20:41

He just cant resist the call of the srl. GJ on script

marpis

2009-07-21 18:25:03


for i:= 0 to 1 do
begin
GameTab(TC[i]);
if FindDTM(AxeDTM, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
Result := true;
Players[CurrentPlayer].Booleans[0] := (TC[i] = tab_Equip);
if Players[CurrentPlayer].Booleans[0] then
RMDebug('Axe is Equipped')
else
RMDebug('Axe in Inv');
exit;
end;
end;

if i > 1 then // !!!
begin
LogOut;
Players[CurrentPlayer].Active := false;
Players[CurrentPlayer].Rand := 'No Axe';
end;
for i := 0 to 1, i is never more than 1. you could just take the whole if-then statement away.

i love custom types! my awesomefighter-to-be has like 6 custom types ^^
I like the idea that you make mouse follow the tree, so you know 100% sure which tree you are chopping, but isn't it a bit bottish?

ZephyrsFury

2009-07-21 18:31:44

From: marpis

for i := 0 to 1, i is never more than 1. you could just take the whole if-then statement away.


Actually SCAR increments your variable at the end of the loop so i would be 2 if he didn't break out before.

Anyway 617 lines… wat! :norris:

Naum

2009-07-21 18:45:57

Looks, Kick-ass :).
Could you use nil instead of @Empty?

Sir R. M8gic1an

2009-07-21 20:52:12

From: marpis

for i:= 0 to 1 do
begin
GameTab(TC[i]);
if FindDTM(AxeDTM, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
Result := true;
Players[CurrentPlayer].Booleans[0] := (TC[i] = tab_Equip);
if Players[CurrentPlayer].Booleans[0] then
RMDebug('Axe is Equipped')
else
RMDebug('Axe in Inv');
exit;
end;
end;

if i > 1 then // !!!
begin
LogOut;
Players[CurrentPlayer].Active := false;
Players[CurrentPlayer].Rand := 'No Axe';
end;
for i := 0 to 1, i is never more than 1. you could just take the whole if-then statement away.

i love custom types! my awesomefighter-to-be has like 6 custom types ^^
I like the idea that you make mouse follow the tree, so you know 100% sure which tree you are chopping, but isn't it a bit bottish?


about the for loop, zeph is right. The value is incremented at the end of the function.

Also, the mouse doesn't follow the tree. The mosue stays still, and once you ahve stopped movign it then goes to the tree, just to make sure it followed the color to the right place ;) This way i can *later* make it move the mouse around, without it hovering over the tree the whole time.

Zeph: 617 lines for a power script sounds quite ok to me :p

~RM

marpis

2009-07-22 00:29:54

woot, how come i didn't know that about for :eek:
that's stoopid i think

ShowerThoughts

2009-07-22 00:42:14

Amazing clean code can you explain about those SetColorSpeed2Modifiers(which.Hue, which.Sat); ? I just don't get it.

ZephyrsFury

2009-07-22 09:40:04

From: Rasta Magician

Zeph: 617 lines for a power script sounds quite ok to me :p

~RM


I can't seem to ever keep my scripts below 2k lines. :(

Sir R. M8gic1an

2009-07-22 16:16:18

From: Hermen
Amazing clean code can you explain about those SetColorSpeed2Modifiers(which.Hue, which.Sat); ? I just don't get it.


Well…

ColorToleranceSpeed(2) uses HSL as the way to search for colors.
SetColorSpeed2Modifiers sets some parameter for the hue and sat mode, don't know the exact term.

Which.Hue and Which.Sat are easy to understand.

I made a Type Record, TTree.


type
TTree = record
Name : string;
Uptext : TStringArray;
Color : Integer;
Tol : Integer;
Hue : extended;
Sat : extended;
width : integer;
hight : integer;
Level : integer;
end;

and then I do this:
function FindTree(which: TTree; var fx, fy: Integer): Boolean;

So 'which' is just simply a var of TTree, and the values are set when i call LoadTree();

@Nauman: i don't think you can call a function when you equal it to nil.

~RM

ShowerThoughts

2009-07-22 16:21:14

I understood the type directly smart use of types btw ;).
I just wanted to know how did you find the right Hue and Sat?

Sir R. M8gic1an

2009-07-22 16:35:42

From: Hermen
I understood the type directly smart use of types btw ;).
I just wanted to know how did you find the right Hue and Sat?


lol. ACA2 ftw.

~RM