SRL Archive - Archive

Bad Boy JH - SRL Member Application


Bad Boy JH

2010-02-07 07:48:20

How Long have You Played Runescape?
3 Year(s)


Are you affilated in anyway with Jagex LTD?
No

Were you Referred to SRL?



What is your general programming knowledge?
Well, Not much…I now know alot of Pascal, which is what I believe SCAR is based on…and I know a bit of Python


Are you a member of any other communities?
Freddy1990 Forums, Not very active there, its basically dead…


Tell us about yourself…
From: Bad Boy JH
I am 16 and now doing my final year of high school. My passion is Psychology and the human brain, which is kinda the opposite of my other interest, which is computing. I love my sport, although more watching it than playing it.



Please show us one (or multiple) of your scripts.
program YewChomper;
{.include srl/srl/misc/smart.scar}
{.Include srl/srl.scar}
Var
SinceBreak:Integer;

const
Axe_Equiped = 0;
Issue = 1;
Logs_To_Cut = 0;
Logs_Cut = 1;
Loads_Done = 2;
Loggedin_For = 3;
Working_Time = 4;
Lamp_Skill = 0;
Which_Task = 1;


/////////////////////////////Setup Starts Here//////////////////////////////////
TakeBreaks = True; //Do You Want to take breaks
BreakAfter = 60; //How Long you want to work for before you take a 15 min break (In Minutes)
World = 37;//Which world you want to use

Procedure DeclarePlayers;
begin
HowManyPlayers := 1 ;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;

with players[0] do
begin
Name := '';
Pass := '';
Nick := '';
Active := True;
Pin := '';
Booleans[Axe_Equiped] := True;
Integers[Logs_To_Cut] := 140;
Strings[Lamp_Skill] := 'woodcutting';
BoxRewards := ['amp', 'mote', 'ostume', 'oins', 'unes', 're', 'ems'];
end;

{ with players[1] do
begin
Name := '';
Pass := '';
Nick := '';
Active := True;
Pin := '';
Booleans[Axe_Equiped] := True;
Integers[Logs_To_Cut] := ;
Strings[Lamp_Skill] := 'woodcutting';
BoxRewards := ['amp', 'mote', 'ostume', 'oins', 'unes', 're', 'ems'];
end;

with players[2] do
begin
Name := '';
Pass := '';
Nick := '';
Active := True;
Pin := '';
Booleans[Axe_Equiped] := True;
Integers[Logs_To_Cut] := ;
Strings[Lamp_Skill] := 'woodcutting';
BoxRewards := ['amp', 'mote', 'ostume', 'oins', 'unes', 're', 'ems'];
end;

with players[3] do
begin
Name := '';
Pass := '';
Nick := '';
Active := True;
Pin := '';
Booleans[Axe_Equiped] := True;
Integers[Logs_To_Cut] := ;
Strings[Lamp_Skill] := 'woodcutting';
BoxRewards := ['amp', 'mote', 'ostume', 'oins', 'unes', 're', 'ems'];
end;}
end;
/////////////////////////////Setup Ends Here////////////////////////////////////

//While you are here, Thanks to the people who made world walker, this allowed//
//for my script to start from anywhere, and will soon allow for my script to //
//recover if it gets lost, thanks alot guys //
//Creators: Zyt3x, Others who i don't know...sorry //

function WW_IsMapUp : Boolean;
begin
Result := CountColor(15000805, 22, 471, 32, 489) = 9;
end;

function WW_GetMapDistance(P1, P2 : TPoint) : Integer;
begin
Result := Round(Distance(P1.x, P1.y, P2.x, P2.y) * 1.0);
end;

procedure WW_CloseMap;
var
T : Integer;
begin
if not WW_IsMapUp then Exit;
Mouse(740, 10, 16, 16, True);
T := GetSystemTime + 15000;
while WW_IsMapUp and (GetSystemTime < T) do
Wait(500);
Wait(500);
end;

function WW_OpenWorldmap : Boolean;
var
T : Integer;
begin
if WW_IsMapUp then
begin
Result := True;
Exit;
end;
MouseBox(527, 139, 559, 156, 1);
Wait(1500);
T := GetSystemTime + 15000;
while (GetColor(230, 196) = 1118604) and (GetSystemTime < T) do
Wait(200);
Result := GetSystemTime < T;
end;

function WW_GetPos(var X, Y : Integer) : Boolean;
begin
Result := False;
if WW_OpenWorldmap then
begin
if GetColor(712, 475) = 16777215 then
MouseBox(742, 464, 757, 479, 1);
if GetColor(606, 308) <> 5860213 then
MouseBox(666, 469, 698, 491, 1);
Result := FindColor(X, Y, 255, 609, 311, 757, 460);
if not Result then
WW_CloseMap;
end;
end;

//WW_Walk(Point(705, 373)); will walk to GE
function WW_Walk(Loc : TPoint) : Boolean;
var
MapDist, I, X, Y : Integer;
Angle, FAngle : Extended;
WalkPoint, Cur : TPoint;
begin
repeat
if WW_IsMapUp then
begin
if FindColor(X, Y, 9100798, 6, 6, 757, 460) then
begin
Mouse(X, Y, 90, 14, True);
Wait(1500);
end else
WW_CloseMap;
end;
WW_OpenWorldmap;
WW_GetPos(Cur.X, Cur.Y);

MapDist := WW_GetMapDistance(Cur, Loc);
Angle := Degrees(ArcTan2(Cur.Y - Loc.Y, Cur.X - Loc.X));
Angle := Angle + 180;
if Angle > 360 then Angle := Angle - 360;
WW_CloseMap;

for I := 1 to MapDist do
begin
FAngle := Angle - rs_GetCompassAngleDegrees;
WalkPoint := RotatePoint(Point(MMCX + 63, MMCY), Radians(FAngle), MMCX, MMCY);
Mouse(WalkPoint.X-2, WalkPoint.Y-2, 4, 4, True);
RunEnergy(30);
while IsMoving do
if (FlagDistance < 20) and (FlagDistance > 0) then Break;
Wait(150);
end;
while IsMoving do
Wait(100);
until(MapDist < 1)
SetAngle(True);
Result := True;
end;

//WW_WalkToLocation('Varrock');
function WW_WalkToLocation(SearchString : String) : Boolean;
var
TargetPos : TPoint;
begin
Result := False;
if WW_OpenWorldmap then
begin
MouseBox(98, 472, 320, 487, 1);
TypeSend(SearchString);
Wait(1000+Random(500));
if not WW_GetPos(TargetPos.X, TargetPos.Y) then
begin
WW_CloseMap;
Exit;
end;
WW_Walk(TargetPos);
end;
end;

Function NotMoving:boolean;
begin
If Ismoving then
Result := False else
Result := True;
end;

Function WalkBankToYews:Boolean;
var
X, Y:integer;
TPA:TPointArray;
begin
Players[CurrentPlayer].Strings[Which_Task] := 'Walking from the Bank to the Trees';
Result := False;
If Runenergy(25) then
SetRun(True);
if not RadialWalkTolerance(6916501, 70, 110, 80 ,-1, 0, 10) then
RadialWalkTolerance(5797500, 70, 110, 80 ,-1, 0, 10);
Flag;
RadialWalkTolerance(6916501, 40, 90, 80, -1 ,-2, 10);
Flag;
if FindSymbol(x, y, 'tree') then
Mouse(x+5, y+8, 5, 5, true) else
RadialWalkTolerance(6916501, 27, 41, 76, -2, -1, 10);
Flag;
wait(1000);
FindSymbols(TPA, 'Tree')
if High(TPA) >= 1 then
Result := True;
end;

Function DotWalk:Boolean;
var
I:Integer;
TBox:Tbox;
TPA:TPointArray;
ATPA:T2DPointArray;
begin
TPA := GetMinimapDots('Yellow');
if length(TPA) >= 0 then
begin
ATPA := TPAToATPAEx(TPA, 25, 25);
SortATPAFrom(ATPA, Point(MSCX, MSCY));
for I := 0 to High(ATPA) do
begin
TBox := GetTPABounds(ATPA[i]);
if High(GetMinimapDotsIn('yellow', TBox.x1, TBox.y1, TBox.x2, TBox.y2)) >= 2 then
begin
Mouse(((Tbox.x1+TBox.x2)/2), TBox.y2 , 5, 5, true)
Flag;
Result := True;
Exit;
end;
end;
end;
end;

Function WalkYewsToBank:boolean;
var
x, y, i, DTM:integer;
begin
Players[CurrentPlayer].Strings[Which_Task] := 'Walking from the Trees to the Bank';
Result := False;
If Runenergy(50) then
SetRun(True);
RadialWalkTolerance(6916501, 210, 250, 80, -1, 0, 10);
Flag;
RadialWalkTolerance(5797500, 260, 280, 80, 1, 0, 10);
Flag;
DTM := DTMFromString('78DA630C626260086400032608C5505D59CAC' +
'00AA41981F83F1030C600659C51D57CF8FD8E8119AA0604C06A3C' +
'8950138D5F0D00055310B5');
if DTMRotated(DTM, x, y, MMX1, MMY1, MMX2, MMY2) then
begin
MMouse(x-20, y, 5, 5);
Flag;
Result := True;
end else
if not dotwalk then
begin
for I := 5 to 16 do
if RadialWalktolerance(264185, 240, 310, 5*i, 1, 1, 10) then
begin
Flag;
break;
end;
end;
FreeDTM(DTM);
WaitFunc(@NotMoving, randomrange(10, 25), 1000);
if FindSymbol(x, y, 'guide') or (CountDots('NPC') >= 7) then
Result := True;
end;

function MiddleATPAOrdered(ATPA:T2DPointArray):TpointArray;
var
TPointArray:TpointArray;
I:integer;
begin
SetArrayLength(TPointArray, high(ATPA)+1)
for i:=0 to high(ATPA) do
TpointArray[i] := middleTPA(ATPA[i]);
SortTPAFrom(TPointArray, Point(MSCX, MSCY))
Result := TPointArray
end;

Procedure Antiban;
begin
case Random(210) of
0 : BoredHuman;
1 : Hoverskill('random', false);
2..4 : Hoverskill('woodcutting', false);
5 : PickUpMouse;
6 : RandomRClick;
end;
WriteLn('*Searching for Randoms*');
FindNormalRandoms;
UseRewardBox;
FindLamp(Players[CurrentPlayer].Strings[Lamp_Skill]);
end;

Function FindTree:boolean;
var
I:integer;
TPoint:TPoint;
TPA:TPointArray;
ATPA:T2DPointArray;
begin
Result := False;
if not (FindColorsTolerance(TPA, 5477768, MSX1, MSY1, MSX2, MSY2, 10)) then Exit;
ATPA := TPAtoATPAEx(TPA, 50, 50)
TPA := MiddleATPAOrdered(ATPA)
Wait(500+Random(1500))
if High(TPA) = -1 then exit;
for I := 0 to high(TPA) do
begin
MMouse(Tpa[i].x, TPa[i].y, 5, 5)
If WaitUpText('ew', 250) then
begin
Getmousepos(Tpoint.x, Tpoint.y)
Mouse(Tpoint.x, TPoint.y, 0, 0, True)
Result := True
Writeln('Found a Tree...Chopping now');
Exit;
end;
end;
end;

//only way to get something to work...


procedure OtherTree;
var
TPA:TPointArray;
begin
if not FindSymbols(TPA, 'tree') then Exit;
SortTPAFrom(TPA, Point(MMCX, MSCY));
InvertTPA(TPA);
if TPA[0].x > MMCX then
Mouse(TPA[0].x-8, TPA[0].y+5, 5, 5, true) else
Mouse(TPA[0].x+5, TPA[0].y+5, 5, 5, true);
Flag;
WaitFunc(@NotMoving, randomrange(10, 25), 1000)
end;

Procedure GroupofPeople;
var
TPoint:TPoint;
TPA:TPointArray;
ATPA:T2DPointArray;
begin
TPA := GetMinimapDots('white');
if High(TPA) = -1 then exit;
ATPA := SplitTPA(TPA, 10);
SortATPASize(ATPA, True);
TPoint := MiddleTPA(ATPA[0]);
if Distance(MSCX, MSCY, TPoint.x, TPoint.y) > 450 then
Begin
Writeln(IntToStr(distance(MSCX, MSCY, TPoint.x, TPoint.y)));
Mouse(TPoint.x, TPoint.y, 5, 5, true);
Flag;
WaitFunc(@NotMoving, randomrange(10, 25), 1000);
end;
end;

Function West:Boolean;
var
TPA:TPointArray;
begin
FindSymbols(TPA, 'tree')
SortTPAFrom(TPA, Point(MMCX, MMCY))
If distance(TPA[0].x, TPA[0].y, TPA[1].x, TPA[1].y) > 35 then
Result := True else
Result := False
end;

procedure Chop;
var
Counter, Timer:integer;
begin
Counter := 1;
MarkTime(Timer);
if not(FindTree) then
begin
if not west then
WaitFunc(@FindTree, randomrange(100, 200), 15000);
OtherTree;
while not(FindTree) do
begin
Wait(RandomRange(500, 1500));
AntiBan;
if InvFull then Exit;
if Timefrommark(timer)>60000 then
begin
OtherTree;
FindTree;
Inc(Counter);
end;
if Timefrommark(timer) > (15000 * counter) then
begin
GroupofPeople;
Inc(counter);
end;
end;
if Timefrommark(timer)>60000 then
begin
OtherTree;
FindTree;
end;
end;
end;

Function MovingCheck:boolean;
var
I, Yes:Integer;
begin
for I := 1 to 5 do
begin
if Animating(IntToBox(MSCX-20, MSCY-20, MSCX+20, MSCY+20), 500, 225) then
Inc(Yes);
Wait(Random(250))
end;
Result := yes >= 3
if not Result then
WriteLn('Moving Check Failed...finding New Tree');
end;

Function TreeInvCheck:boolean;
var
I, Yes:Integer;
begin
Result := False;
for I := 1 to 5 do
begin
if InvFull or (CountColorTolerance(1460797, MSCX - 60, MSCY - 50, MSCX + 60, MSCY + 50, 10) > 30) then
Inc(Yes);
Wait(Random(250))
end;
Result := yes >= 3
if not Result then
WriteLn('Tree & Inv Check Failed...finding New Tree');
end;

Function IsChopping:boolean;
begin
If MovingCheck or TreeInvCheck then
Result := True else
Result := True;
end;

Procedure ChopALoad;
begin
Players[CurrentPlayer].Strings[Which_Task] := 'Chopping the Trees';
Chop;
Wait(randomrange(5000, 8000));
repeat
if not ischopping then
Chop;
Wait(randomrange(2500, 5000));
AntiBan;
until InvFull;
If West then
RadialWalkTolerance(6916501, 260, 280, 80, 1, 0, 10);
end;

Function OpenTheBank:boolean;
var
I, X, Y:Integer;
TPA:TPointArray;
ATPA:T2DPointArray;
begin
Result := False
if not FindColorsTolerance(TPA, 6381925, MSX1, MSY1, MSX2, MSY2, 5) then exit;
ATPA := TPAtoATPAEx(TPA, 20, 15);
TPA := MiddleATPAOrdered(ATPA);
For I := 0 to high(ATPA) do
begin
MMouse(TPA[i].x, TPA[i].y, 5, 5);
wait(random(250)+125);
if WaitUpText('anker', 250) then
begin
GetmousePos(x, y);
Mouse(x, y, 0, 0, False);
ChooseOption('ank Banker');
if Waitfunc(@NotMoving, randomRange(25, 50), 3000) then
begin
Result := True
wait(500+random(1000));
Exit;
end;
end;
end;
end;

Procedure PRPart(WhichPlayer:integer);
var
Loads, LoggedFor:Integer;
begin
writeln('Player: ' + Players[WhichPlayer].Name);
writeln('Logs Cut: ' + Inttostr(Players[WhichPlayer].Integers[Logs_Cut]));
writeln('Loads Done: ' + Inttostr(Players[WhichPlayer].Integers[Loads_Done]));
writeln('Experience Gained: ' + Inttostr(Players[WhichPlayer].Integers[Logs_Cut] * 175));
Loads := Players[WhichPlayer].Integers[Loads_Done];
LoggedFor := Players[WhichPlayer].Integers[Working_Time];
if loads <> 0 then
Writeln('Average Time to do a load: ' + MsToTime(LoggedFor/Loads, Time_Abbrev));
if Players[CurrentPlayer].Booleans[Issue] then
writeln('Player Ran into an issue whilst ' + Players[WhichPlayer].Strings[Which_Task] + '.');
end;

Procedure ProgressReport(WhichPlayer:Integer);
var
I:Integer;
begin
writeln('/////////////////////////////////////////////////////////////////');
writeln('////////////Thanks For Using Bad Boy JHs Yew Chomper/////////////');
writeln('/////////////////////////////////////////////////////////////////');
if WhichPlayer = -1 then
begin
for I := 0 to HowManyPlayers-1 do
begin
PRPart(I);
writeln('//////////////////////////////////////////////////////////////////');
end;
end else
begin
PRPart(WhichPlayer)
writeln('//////////////////////////////////////////////////////////////////');
end;
end;

Function Bank:boolean;
var
Slot, LogsDTM, LogsInInvo, X, Y, GEIcon:Integer;
TBox:TBox;
TPA:TPointArray;
ATPA:T2DPointArray;
begin
Result := False;
Players[CurrentPlayer].Strings[Which_Task] := 'Banking';
if not OpenTheBank then
begin
AntiBan;
If not OpenTheBank then
begin
writeln('cant find the bank, lets relocate...')
DotWalk;
if not OpenTheBank then
begin
GEIcon := BitmapFromString(13, 10, 'beNpjYKgoK2ZgYDwABosNGH' +
'/+E/y0gXF9OSMDA8M/MACKA9lgZQwQZUCGoxqDkwIDRCOQZAABKHk' +
'ABoAcd3UeIIILAk2rKCtCVuYAZBowBtgwOsBMQ7YUIhJiq/vi5toP' +
'x0ue7p7eEKkJdBvE0kePHsEtBZoDUTPB1QAsyAjUJSCrCXMeI9wLG' +
'5oSNriaTAg1mCCgxcDMosAsAjEBKAtRAA8QoAkq0qJABPE4RApZGU' +
'QlzA0MsEBgRFZGFAAAIAZy9Q==');
If not FindBitmapTolerance(GEIcon, x, y, 20) then
begin
FindColorsTolerance(TPA, 264185, MMX1, MMY1, MMX2, MMY2, 10);
ATPA := TPAToATPAEx(TPA, 25, 25);
TBox := GetTPABounds(ATPA[0]);
Mouse(TBox.x2, ((TBox.y1 + Tbox.y2)/2), 5, 5, True);
Flag;
end;
FreeBitmap(GEIcon);
if not openthebank then exit;
end;
end;
if not WaitFunc(@BankScreen, RandomRange(25, 50), 2000) then
begin
Writeln('couldnt open the bank')
Result := False;
exit;
end;
end;
LogsDTM := DTMFromString('78DA6374666260B8C700064C108AC1CD988B8' +
'115483302F17F20603407CADC475503623141D58000A33B90F796' +
'801A7F20EF0901351E40DE4DFC6A00FE300A72');
LogsInInvo := CountItems('dtm', LogsDTM, []);
Writeln('Found ' + Inttostr(LogsInInvo) + ' yew logs in inventory.')
IncEx(Players[CurrentPlayer].Integers[Logs_Cut], LogsInInvo);
Inc(Players[CurrentPlayer].Integers[Loads_Done]);
if Players[CurrentPlayer].Booleans[Axe_Equiped] then
DepositAll else
begin
if FindDTM(LogsDTM, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
Slot := CoordsToItem(x, y)
Deposit(Slot, Slot, True);
end else
Deposit(2, 28, true);
end;
If CountItems('dtm', LogsDTM, []) = 0 then
Result := True;
FreeDTM(LogsDTM);
Closebank;
if Players[CurrentPlayer].Integers[Logs_Cut] <= Players[CurrentPlayer].Integers[Logs_To_Cut] then
ProgressReport(CurrentPlayer);
Disguise(Inttostr(Players[CurrentPlayer].Integers[Logs_Cut]) + ' Logs Chopped');
end;

Procedure TakeABreak;
var
LastBreak, BreakTime:Integer;
Begin
BreakTime := BreakAfter*60*1000;
incex(BreakTime, (-5*60*1000));
Incex(BreakTime, Random(10*60*1000));
LastBreak := TimeFromMark(SinceBreak)
If TakeBreaks and (BreakTime <= LastBreak) then
begin
Logout;
incex(Players[CurrentPlayer].Integers[Loggedin_For], LastBreak);
writeln('Player Logged in for a total time of ' +
MsToTime(Players[CurrentPlayer].Integers[Loggedin_For], Time_Short));

writeln('//////////////////////////////////////////////////////////////////')
writeln('Taking a quick 15 minute break');
Wait(RandomRange(10*60*1000, 20*60*1000));
LoginPlayer;
SetAngle(True);
MarkTime(SinceBreak);
end;
end;

Procedure ScriptTerminate;
begin
incex(Players[CurrentPlayer].Integers[Loggedin_For], TimeFromMark(SinceBreak));
ProgressReport(-1);
writeln('Script Ran for: ' + TimeRunning);
writeln('//////////////////////////////////////////////////////////////////');
if loggedin then
logout;
end;

Function PlayAPlayer:Boolean;
var
TPA:TPointArray;
X, Y, Timer, LogsDTM:integer;
Begin
if invfull then
begin
Dec(Players[CurrentPlayer].Integers[Loads_Done]);
LogsDTM := DTMFromString('78DA6374666260B8C700064C108AC1CD988B8' +
'115483302F17F20603407CADC475503623141D58000A33B90F796' +
'801A7F20EF0901351E40DE4DFC6A00FE300A72');

DecEx(Players[CurrentPlayer].Integers[Logs_Cut], CountItems('dtm', LogsDTM, []));
end;
MarkTime(SinceBreak);
WaitFunc(@LoggedIn, RandomRange(10, 25), 2000);
wait(RandomRange(2000, 4000));
if FindSymbol(x, y, 'guide') or (CountDots('NPC') >= 7) then
begin
Writeln('Starting Location: Grand Exchange');
If InvFull then
begin
Writeln('You started with stuff in your inventory, lets bank them...');
if not Bank then exit;
end;
end else

begin
FindSymbols(TPA, 'Tree')
if High(TPA) >= 1 then
begin
Writeln('Starting Location: Trees');
if not InvFull then
begin
Writeln('Now Chopping Trees');
MarkTime(Timer);
ChopALoad;
end else
begin
Writeln('You started with full inventory, Going to bank them now...');
If West then
RadialWalkTolerance(6916501, 260, 280, 80, 1, 0, 10);
end;
if not WalkYewsToBank then exit;
if not Bank then exit;
if not(Timer = 0) then
incex(Players[CurrentPlayer].Integers[Working_Time], TimeFromMark(Timer));


end else

begin
Writeln('Cant Detect Location, Using World Walker to go to the grand exchange');

If InvFull then
begin
WW_Walk(Point(704, 373));
if not Bank then exit;
end else
begin
WW_Walk(Point(707, 372));
MarkTime(Timer);
ChopALoad;
if not WalkYewsToBank then exit;
if not Bank then exit;
incex(Players[CurrentPlayer].Integers[Working_time], TimeFromMark(Timer));
end;
end;
end;

repeat
MarkTime(Timer);
if not WalkBankToYews then exit;
ChopALoad;
if not WalkYewsToBank then exit;
if not Bank then exit;
incex(Players[CurrentPlayer].Integers[Working_time], TimeFromMark(Timer));
TakeABreak;
until(Players[CurrentPlayer].Integers[Logs_Cut] >= Players[CurrentPlayer].Integers[Logs_To_Cut]);
Result := True;
end;

Procedure PickWorld;
var
SWorld:Integer;
Begin
WaitFunc(@RSReady, 25, 60000);
OpenWorldScreen;
WaitFunc(@WorldScreen, 25, 5000);
if world=0 then
SWorld := 119 else
SWorld := World;
if not SelectWorld(SWorld) then
Writeln('couldnt select world requested, running script anyway');
end;

begin
Smart_Members := False;
Smart_Signed := True;
Smart_SuperDetail := False;
SetupSRL;
DeclarePlayers;
PickWorld;
LoginPlayer;
SetAngle(True);
repeat
If not PlayAPlayer then
begin
Players[CurrentPlayer].Booleans[Issue] := True;
ProgressReport(CurrentPlayer);
end;
if not(PlayersActive = 1) then
begin
IncEx(Players[CurrentPlayer].Integers[Loggedin_For], TimeFromMark(SinceBreak));
NextPlayer(False)
SetAngle(True);
end else
begin
Players[CurrentPlayer].Active := False;
Logout;
end;
Until AllPlayersInactive;
end.

Sir R. M8gic1an

2010-02-07 08:00:48

Your walking needs more failsafes. Other than that, good job.

I like how you used constants for you PlayerArray.

~RM

Bad Boy JH

2010-02-07 16:03:17

I saw coh3n use them, and I thought that was a brilliant idea…I don't think i should have given credit in script, but don't praise me for doing it :)

Sir R. M8gic1an

2010-02-07 16:34:52

From: Bad Boy JH
I saw coh3n use them, and I thought that was a brilliant idea…I don't think i should have given credit in script, but don't praise me for doing it :)


Good to know you've been learning from other scripts ;) Praise is indeed due not because it is original, but because it's good.

~RM

Bad Boy JH

2010-02-08 23:29:28

to whomever voted no, can I ask for a reason? I would rather know why, so that I can improve…

NCDS

2010-02-08 23:50:06

I don't really have time to do a full mark up but I'm going to vote yes.

You have a good use of TPA's which is a big plus. Arrays in general are such a great tool.

A lot of things could be improved but it is definitely members worthy.

I might go back through it tomorrow to point out a few things.

Nice job :)

Dynamite

2010-02-09 13:12:14

Procedure WalkBankToYews;
var X, Y:integer;
begin
RadialWalkTolerance(6916501, 70, 110, 80 ,-1, 0, 10);
Flag;
RadialWalkTolerance(6916501, 40, 90, 80, -1 ,-2, 10);
Flag;
if FindSymbol(x, y, 'tree') then
Mouse(x-5, y+8, 5, 5, true) else
RadialWalkTolerance(6916501, 27, 41, 76, -2, -1, 10);
Flag;
wait(1000);
end;

Procedure WalkYewsToBank;
var
x, y, DTM:integer;
begin
RadialWalkTolerance(6916501, 210, 250, 80, -1, 0, 10);
Flag;
RadialWalkTolerance(5797500, 260, 280, 80, 1, 0, 10);
Flag;
DTM := DTMFromString('78DA630C626260086400032608C5505D59CAC' +
'00AA41981F83F1030C600659C51D57CF8FD8E8119AA0604C06A3C' +
'8950138D5F0D00055310B5');
if DTMRotated(DTM, x, y, MMX1, MMY1, MMX2, MMY2) then
begin
MMouse(x-20, y, 5, 5);
Flag;
end else
RadialWalktolerance(198126, 264, 292, 70, 1, 1, 10);
FreeDTM(DTM)
end;

I suggest using TPA's for walking.
Or even try using a DDTM.
TPA's are the most accurate and I see you know them because you use them in your FindTree.

Apart from that, pretty good :)

Yes from me.

T~M

Blumblebee

2010-02-09 16:08:24

From: The Man
Procedure WalkBankToYews;
var X, Y:integer;
begin
RadialWalkTolerance(6916501, 70, 110, 80 ,-1, 0, 10);
Flag;
RadialWalkTolerance(6916501, 40, 90, 80, -1 ,-2, 10);
Flag;
if FindSymbol(x, y, 'tree') then
Mouse(x-5, y+8, 5, 5, true) else
RadialWalkTolerance(6916501, 27, 41, 76, -2, -1, 10);
Flag;
wait(1000);
end;

Procedure WalkYewsToBank;
var
x, y, DTM:integer;
begin
RadialWalkTolerance(6916501, 210, 250, 80, -1, 0, 10);
Flag;
RadialWalkTolerance(5797500, 260, 280, 80, 1, 0, 10);
Flag;
DTM := DTMFromString('78DA630C626260086400032608C5505D59CAC' +
'00AA41981F83F1030C600659C51D57CF8FD8E8119AA0604C06A3C' +
'8950138D5F0D00055310B5');
if DTMRotated(DTM, x, y, MMX1, MMY1, MMX2, MMY2) then
begin
MMouse(x-20, y, 5, 5);
Flag;
end else
RadialWalktolerance(198126, 264, 292, 70, 1, 1, 10);
FreeDTM(DTM)
end;

I suggest using TPA's for walking.
Or even try using a DDTM.
TPA's are the most accurate and I see you know them because you use them in your FindTree.

Apart from that, pretty good :)

Yes from me.

T~M


radialwalk is TPA walking…and he uses DTM walking which I applaud him for because most people use DDTM walking because it "looks cool" and don't implement a DDTM properly.

@Bad Boy JH
I'm a little hesitant because I'm a stiff when it comes to walking, you have the concepts down but you don't fully implement the power of a boolean function (if radialwalktolerance() then else etc) but other than that well done.

You've come a long way in a short amount of time, and even though sometimes you have a lil' tude I like you, so yes

Awkwardsaw

2010-02-09 16:52:52

use more failsafes in walking like every one has said :p

and also, RW IS tpa walking. RWEx does the exact same as finding a color tpa, and filterpoints pie.

also, rw has flag built in, so you dont have to really have it afterwords :)

i'll vote later, since i havnt really looked at the script

noidea

2010-02-09 17:59:48

yep

Bad Boy JH

2010-02-09 19:58:02

Actually RadialWalkTolerance has Flag(10), which to me, doesn't seem enough…

Also I had the most recent version do 308 logs last night, before stopping.

Also, I don't know why, but DDTM and DTM walking, have all not worked, I don't know why, I used DTM Rotated, but it doesn't want to work…ARGH!

jimmy_mac

2010-02-10 20:29:13

Hey, this is all constructive cristicism/tips, not having a go just trying to help. :)

alright, remove the 'Axe_Equiped' from the const so that it looks like this:
 const
Logs_To_Cut = 0;
Logs_Cut = 1;
Loads_Done = 2;
Lamp_Skill = 0;
You can also remove all of these in the declare players:
Booleans[Axe_Equiped] := True;
You aren't using those at all during your script so they are just useless.

Maybe change the RadialWalking from this:
RadialWalkTolerance(6916501, 210, 250, 80, -1, 0, 10);
Flag;
to this:
if RadialWalkTolerance(6916501, 210, 250, 80, -1, 0, 10) then Flag else
begin
Fail := True;
exit;
end;

Adding a boolean check into the start of all the procedures to check whether anything has failed or not is a really good idea aswell, for example:
Procedure CheckLogs;
begin
if Fail then exit;
blah;...
end;
You can set the boolean fail to true with any other circumstance, not just walking. And then when the next player is activated change the value to false.

In the antiban procedure change this:
FindNormalRandoms;
UseRewardBox;
FindLamp(Players[CurrentPlayer].Strings[Lamp_Skill]);
to this:
if FindNormalRandoms then
begin
UseRewardBox;
FindLamp(Players[CurrentPlayer].Strings[Lamp_Skill]);
end;

You should also change the IsChopping function from this:
Function IsChopping:boolean;
begin
case random(2) of
0 : Result := MovingCheck;
1 : Result := TreeInvCheck
end;
end;
to this:
Function IsChopping:boolean;
begin
if MovingCheck or TreeInvCheck then Result:=True
else Result := False;
end;
this would make it so that it check the other if one fails.

Also fail safes need to be added to ChopALoad, as it is a potential unlimited loop. maybe add
if fail then exit;
and in the Chop procedure add a fail boolean in there if it doesn't find a tree.

Also another tip, standards:
There are a lot of semicolons missing. You should get used to adding semicolons after every procedure/function.

Other than that, looks pretty good. Keep up the good work.

Bad Boy JH

2010-02-11 00:42:11

This was the first release of the script, with not all features released, at the stage of that, I hadn't worked in a way to not deposit the axe, but I have now, so that 1st thing, no longer needs to happen, but in that script, it was unnecessary…
Yes failsafes aren't great yet, but…I have improved them since then…
Script Here
Check the script for the updated version, it has more failsafes, but a few minor errors that i haven't uploaded the fix for (Can you believe i tried to find something in the area: Tbox.x1, TBox.y1, TBox.x1, TBox.y2 What a brilliant error, no wonder it kept failing!

jimmy_mac

2010-02-11 00:52:38

you can just edit the first post with the updated script if you want.

Gu3st...

2010-02-11 04:29:27

I think it's safe to say that you will probably get in :)

Bad Boy JH

2010-02-12 07:59:52

I don't mean to sound impatient, but its 13-1 in favour, and there hasn't been a vote for a couple of days…

Dynamite

2010-02-12 08:09:56

"This poll will close on 02-21-2010 at 12:48 PM"
Or an admin will decide to close earlier.

Cigue

2010-02-12 16:23:25

I'll just vote yes, even though I haven't seen you around the community. Nice script, the world walker and TPA finding is a great plus ! :p

I think it's safe to say, welcome to SRL Members !

Naum

2010-02-12 16:29:58

Basically what everyone else said, improvements-wise; but I thought I'd cite my opinion: yes!

EDIT, Lol I swear there's always one person who keeps voting no on all apps :-/

Bionicle

2010-02-12 17:02:31

From: Naum
Basically what everyone else said, improvements-wise; but I thought I'd cite my opinion: yes!

EDIT, Lol I swear there's always one person who keeps voting no on all apps :-/


Yes, it is getting really annoying tbh :/

Dido what everyone else said…and me says yes!
Welcome to teh club!

Cigue

2010-02-12 18:32:31

From: bionicle1800
Yes, it is getting really annoying tbh :/


I made my appliance trying to get no no's. This bugged me. :p

Bad Boy JH

2010-02-12 18:44:46

From: The Man
"This poll will close on 02-21-2010 at 12:48 PM"
Or an admin will decide to close earlier.


I can't see that message, but thanks for telling me :D

Sir R. M8gic1an

2010-02-13 05:22:29

Welcome to Jah People :)

~RM