SRL Archive - Archive

johnbrown8976 - SRL Member Application


johnbrown8976

2012-04-07 02:49:36

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


Are you affilated in anyway with Jagex LTD?
No

Were you Referred to SRL?
No


What is your general programming knowledge?
I have written lots of java applets in my undergraduate research including a wireless sensor network simulation using 2D grahpics. I am good in java, but can code in python, php, and javascript. I am new to pascal but found it quite easy to pick up. I created my own Gilded Altar script, and Nature runecrafting scripts, in the last couple weeks, but they are buggy, so I am submitting AstralRunecrafter which is a lot more organized


Are you a member of any other communities?
No


Tell us about yourself…
From: johnbrown8976
I am a undergraduate student at Grambling State University, USA, majoring in Computer Science, graduating May 2012. I have been coding only in Java since 2007, but am interested in learning C and its derivatives. I have presented my java projects in Wireless Sensors Network. I learned PHP, python, javascript, HTML in my high school, and have quite good knowledge of scripting language. My interest is software coding, my dream is to be a software engineer. I usually code for hours for my undergraduate assignments, and find it entertaining.



Please show us one (or multiple) of your scripts.

program AstralRuneSlowAndSteady;
{$DEFINE SMART} // This is how we include SMART; it HAS to be called BEFORE SRL!
{$i srl/srl.simba}
{$i sps/sps.simba}
{$i SRL/SRL/misc/paintsmart.simba}

Procedure DeclarePlayers;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;
Players[0].Name :='';
Players[0].Pass :='';
Players[0].Nick :='';
Players[0].Active:=True;
Players[0].Pin := ''; //Leave blank if the player doesn't have a bank pin
end;

var
//Global Variables
TotalEssenceCrafted, ExtraEssenceFromPouch, SuccessTrip, MaxTrips, //Variables used in Paint
StartTime, ElapsedTime, MaxRetryTimeLimit, MaxFailureCount, //Uses markTime to detect if Stuck
FailureCount:Integer; //How many times failed/stuck
Status: String;//Current Status e.g Walking to Bank
CompleteTrip,//Confirms that all steps to Altar complete without error
ForceCloseScript:Boolean; //FailSafe to forceClose Loop if stuck.

Procedure Initialize;
begin
{************Instructions*************
**************************************
1. Place Pouches (small, medium, large) on [FIRST 3 SLOTS]
-No support for Giant Pouch.
-Automatically repairs pouch using NPC contact.
-Detects degraded Large Pouch, assuming Medium degrades later
2. Place Pure Essence, Astral rune, Air rune, Cosmic rune VISIBLE on bank
-Runes are used for NPC contact spell to repair pouch.
-REQUIREMENT: Lunar SpellBook Activated
3. Start the script anywhere on Runescape
-Teleports to Lunar Isle Loadstone on startup.
-REQUIREMENT: Lunar Isle Loadstone unlocked.
**************************************
**************************************}

TotalEssenceCrafted := 0;
SuccessTrip := 0; //Successful trip
MaxTrips := 300;
FailureCount := 0;
MaxRetryTimeLimit := 20000; //Retry time for each action
MaxFailureCount := 10; //Terminate script if stuck too many times
end;


Procedure Proggy;
begin
ClearDebug;
writeln('########################################################');
writeln('#############JohnBrown Astral Runecrafter###############');
writeln('########################################################');
writeln('Time Running :' + TimeRunning);
writeln('Successful Trips :' + IntToStr(SuccessTrip) + ' (Limit ' + IntToStr(MaxTrips) + ')');
writeln('Failed Trips :' + IntToStr(FailureCount) + ' (Limit ' + IntToStr(MaxFailureCount) + ')');
writeln('Essence Crafted :' + IntToStr(TotalEssenceCrafted));
writeln('########################################################');
writeln('########################################################');
writeln('');
end;


Function FindObjectUsingTPA(color, tol, dist, ranX, ranY, clickType:Integer; upText:array of string):Boolean;
Var
x, y: Integer;
TPA: TPointArray;
TPA_Array: T2DPointArray;
i, TPA_Length: Integer;
begin
if not FindColorsSpiralTolerance(MSCX,MSCY,TPA,color,MSX1,MSY1,MSX2,MSY2,tol) then
exit;

TPA_Array := SplitTPA(TPA,dist);
TPA_Length := High(TPA_Array);
SortATPASize(TPA_Array, true);//sorts the biggest Area first

for i:=0 to TPA_Length-1 do
begin
wait(50+random(50));
if MiddleTPAEx(TPA_Array[i], x, y) then
begin
MMouse(x,y,ranX,ranY);
wait(100+random(75));
if IsUpTextMultiCustom(upText) then
begin
ClickMouse2(clickType);
Result := True;
exit;
end;
end;
end;
Result := False;
end;


Procedure AntiBan;
begin
if(not(LoggedIn))then
Exit;
FindNormalrandoms;

case random(80) of
0: begin
HoverSkill(SKILL_RUNECRAFTING, false);
wait(1987 + random(432));
end;
10: PickUpMouse;
20: begin
MakeCompass('N');
wait(160 + random(43));
MakeCompass('S');
wait(84 + random(133));
MakeCompass('N');
FindNormalrandoms;
end;
30: randomMovement;
40: BoredHuman;
50: ExamineInv;
60: randomRClick;
70: SetAngle(SRL_ANGLE_LOW);
79: SetAngle(SRL_ANGLE_NONE);
end;
end;


Procedure SmartGraphics;
var
box:TBox;
x1, y1, x2, y2: Integer;
begin
x1 := 15;
y1 := 200;
x2 := 400;
y2 := 280;
//Paints the Canvas with Status Report
box := IntToBox(x1-10, y1-10, x2, y2);
SMART_DrawBoxEx(true, box, clWhite);
SMART_DrawText(x1, y1, StatChars, 'Status : ' + Status,clWhite);
SMART_DrawText(x1, y1+20, StatChars, 'Time : ' + TimeRunning,clWhite);
SMART_DrawText(x1, y1+40, StatChars, 'Trip : Success(' + IntToStr(SuccessTrip) +
') Fail(' + IntToStr(FailureCount) +
') Maximum(' + IntToStr(MaxTrips) + ') ',clWhite);
SMART_DrawText(x1, y1+60, StatChars, 'Essence Crafted: ' + IntToStr(TotalEssenceCrafted),clWhite);
end;


Procedure Output(OutputString:String; elapsedTime:Integer);
var
timeString:string;
begin
if elapsedTime<>0 then
timeString := ' (' + IntToStr((MaxRetryTimeLimit-elapsedTime) div 1000) + ' seconds)';
Status := OutputString + timeString;
SmartGraphics;
end;


Function OpenBankScreen:Boolean;
begin
Output('Starting up.',0);
wait(500 + random(500));
SetAngle(SRL_ANGLE_HIGH);

MarkTime(StartTime);
repeat //Loops until Bank Screen
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;

Output('Searching Banker.',ElapsedTime);
if FindObjectUsingTPA(4033386, 10, 10, 2, 2, mouse_Right, ['al Banker','Sirsal','anker']) then
begin
Output('Banker found. Banking.',ElapsedTime);
wait(100 + random(150));
ChooseOption('ank Sirsal');
wait(3000 + random(500));//Wait for Banking to complete
end;
until BankScreen;
Result := True;
end;


Function RepairPouch:Boolean; //repair pouch using NPC contact
var
dtm_air, dtm_cosmic, dtm_astral, dtm_NPC, x, y:Integer;
begin
dtm_air := DTMFromString('mggAAAHicY2NgYJgFxBOBeDIQzwTiZUC8HIhXAfEKIF4HxBuBeBNU7vq5syiYgYEJjEWAJDbMiANDAADo3xH+');
dtm_cosmic := DTMFromString('mlwAAAHicY2dgYDgGxGeA+CyUfRiILwDxFSBeAcRLgHgNEG8A4p1AvA2IVwFxSUE+w8VzsnDMwMAExyJAEhdmxIOhAAAvPhF1');
dtm_astral := DTMFromString('mbQAAAHicY2VgYDBjZGCwA2IrIDYAYl0grgTiciBugGIQ+9DKQwwt9XUMuRkZDBEhIWC+CFA/OmbEgsEAAPq2DAM=');
dtm_NPC := DTMFromString('mlwAAAHicY2dgYFBnZGAwBGI5INYAYmUg1gNibSB2A2IXKLYHYm8g9gJifyB+/foVUDcjViwCJHFh7DogGAoAhLsGeg==');

Output('Repairing Pouch.',0);
wait(2000+random(200));
if not OpenBankScreen then
exit;

Output('Withdrawing runes for NPC contact.',0);
wait(1000+random(200));
if not WithdrawItem(dtm_air, 'DTM', 1, 'une', [10]) then
exit;
wait(500+random(200));
if not WithdrawItem(dtm_air, 'DTM', 1, 'une', [10]) then
exit;

wait(1000+random(200));
if not WithdrawItem(dtm_astral, 'DTM', 1, 'une', [10]) then
exit;

wait(1000+random(200));
if not WithdrawItem(dtm_cosmic, 'DTM', 1, 'une', [10]) then
exit;

if BankScreen then
begin
wait(400 + random(200));
CloseBank;
end;

wait(400 + random(200));
GameTab(tab_Magic);
Output('Clicking NPC contact teleport spell', 0);
wait(2000+random(200));

if FindDTM(dtm_NPC, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
wait(200+random(200));
Mouse(x, y, 5, 5, mouse_Left);

Output('Waiting for the List of NPC to appear', 0);
wait(4000+random(200));
Mouse(420,315,40,2,mouse_Right);

Output('Select speak to NPC', 0);
wait(1000+random(200));
ChooseOption('peak');
Output('Contacting NPC, please wait.',0);
wait(10000);

Output('Conversation with NPC',0);
MarkTime(startTime);
while not ClickContinue(true, true) do
begin
wait(100+random(100));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
ClickContinue(true,true);
end;
while not ClickContinue(true, true) do
begin
wait(100+random(100));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
ClickContinue(true,true);
end;
while not ClickContinue(true, true) do
begin
wait(100+random(100));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
ClickContinue(true,true);
end;
while not ClickContinue(true, true) do
begin
wait(100+random(100));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
ClickContinue(true,true);
end;
while not ClickContinue(true, true) do
begin
wait(100+random(100));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
ClickContinue(true,true);
end;
while not ClickContinue(true, true) do
begin
wait(100+random(100));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
ClickContinue(true,true);
end;

//Selects 1, Might mistime click (I don't know how to read text)
wait(1000);
SendKeys('1',200);
wait(1000);

while not ClickContinue(true, true) do
begin
wait(100+random(100));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
ClickContinue(true,true);
end;
while not ClickContinue(true, true) do
begin
wait(100+random(100));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
ClickContinue(true,true);
end;
end;
FreeDTM(dtm_air);
FreeDTM(dtm_cosmic);
FreeDTM(dtm_astral);
FreeDTM(dtm_NPC);
Result := True;
end;


Function StartBanking:Boolean;
var
dtm_pureEss, dtm_pouchL, dtm_pouchM, dtm_pouchS, dtm_pouchLD,
x,y:Integer;
begin
FindNormalrandoms;
wait(1000);

//Degraded Large pouch
dtm_pouchLD := DTMFromString('mrAAAAHic42BgYHjHyMDwnBFCfwHiH0D8Aog/APFbIA4C4jAgjoDiYCD2BWJvIHYBYktTQwZHGwswra2hyqCqpMBgZ2XGEBjoxiAlxcEgArQDH2YkgGEAAIYCD2A=');

GameTab(tab_Inv);
wait(1000);
if FindDTM(dtm_pouchLD, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
Output('Found Degraded Large Pouch. Repairing.',0);
wait(2000);
if not RepairPouch then
begin
Output('Error: Cannot repair pouch',0);
wait(2000);
ForceCloseScript := True;
Logout;
exit;
end;
end;

wait(1000);
dtm_pureEss := DTMFromString('mggAAAHicY2NgYKgE4hwgLgDiBiBuB+IOIL4ExfeA+AEQ3wDi8yC1GRlAkgkDiwBJLiyYEQeGAACPWQmG');
dtm_pouchL := DTMFromString('mwQAAAHic42RgYOhiZGCYDsSTgbgdiBuAuAmIW4C4G4gnAbE/EAcAcTgQRwJxGBB7A7EjEDsAsTMQ+7haAU1jwotFgCQhzEgEhgMAYt4JRg==');
dtm_pouchM := DTMFromString('mrAAAAHic42BgYEhgZGCIAeIIII4F4iwgTgfiTCCOBmJ/IPYA4kComiAg9gRiRyC2B+JgHwegKUw4sQiQxIcZCWAYAACEBQcP');
dtm_pouchS := DTMFromString('m1gAAAHic42JgYDBjZGDQB2JdILYBYgcgtgZiPSA2goobA7EfEHsBcTAQh0H5ILUuQBwK5dsDcaCXHdBUJoJYBEgSgxmJxAgAAA9OBto=');

if not OpenBankScreen then
exit;

wait(1000 + random(200));
Deposit(4,28,True);// Deposit items 4-28
wait(300 + random(100));

if not WithdrawItem(dtm_pureEss, 'DTM', 28, 'ure', [10]) then
begin
Output('Error: Out of pure essence.',0)
ForceCloseScript := True;
Logout;
Result := False;
exit;
end;

wait(1000+random(100));
ExtraEssenceFromPouch := 0; //Counts essence in pouch

if FindDTM(dtm_pouchS, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
wait(200+random(100));
Mouse(x, y, 5, 5, mouse_Right);
ChooseOption('ill Small');
ExtraEssenceFromPouch := extraEssenceFromPouch + 2;
end;

if FindDTM(dtm_pouchM, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
wait(200+random(100));
Mouse(x, y, 5, 5, mouse_Right);
ChooseOption('ill Medium');
ExtraEssenceFromPouch := extraEssenceFromPouch + 5;
end;

if FindDTM(dtm_pouchL, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
wait(200+random(100));
Mouse(x, y, 5, 5, mouse_Right);
ChooseOption('ill Large');
ExtraEssenceFromPouch := extraEssenceFromPouch + 8;
end;

wait(500+random(200));
WithdrawItem(dtm_pureEss, 'DTM', 28, 'ure', [10]);

if BankScreen then
begin
wait(400 + random(200));
CloseBank;
end;

FreeDTM(dtm_pureEss);
FreeDTM(dtm_pouchL);
FreeDTM(dtm_pouchM);
FreeDTM(dtm_pouchS);

Antiban;
wait(700 + random(300));
Result := true;
end;


Function Walk_BankToAltar:Boolean;
var
path: array[0..4] of TPointArray;
randomPath: Integer;
begin
FindNormalrandoms;
SPS_Setup(RUNESCAPE_SURFACE,['0_2','0_3']);
SetAngle(SRL_ANGLE_HIGH);
Output('Walking towards Altar',0);
path[0] := [Point(230, 950),Point(240, 975),Point(265, 975),Point(290, 995),Point(275, 1060),Point(275, 1100),Point(315, 1145),Point(350, 1160),Point(415, 1160),Point(450, 1150),Point(450, 1190)];
path[1] := [Point(239,959),Point(274,972),Point(309,1000),Point(275,1060),Point(291,1113),Point(325,1143),Point(373,1170),Point(407,1180),Point(437,1153),Point(466,1175)];
path[2] := [Point(248,959),Point(275,961),Point(296,1000),Point(289,1062),Point(300,1109),Point(331,1150),Point(377,1189),Point(411,1175),Point(449,1167),Point(455,1180)];
path[3] := [Point(240,966),Point(282,963),Point(301,1012),Point(295,1076),Point(305,1120),Point(330,1144),Point(357,1164),Point(420,1184),Point(456,1175),Point(485,1185)];
path[4] := [Point(243,967),Point(271,981),Point(310,1016),Point(288,1064),Point(308,1133),Point(337,1155),Point(368,1172),Point(412,1172),Point(447,1181),Point(461,1190)];
randomPath := random(5);
Result := SPS_WalkPath(path[randomPath]);
end;


Function CraftAstralRunes:Boolean;
//Returns false if cannot find Astral rune in inventory after crafting
var
extend:extended;
x,y,dtm_astral_rune, dtm_pouchS, dtm_pouchM, dtm_pouchL:Integer;

begin
FindNormalrandoms;
wait(1500 + random(1000));//wait for character to come to COMPLETE STOP
dtm_astral_rune := DTMFromString('mbQAAAHicY2VgYDBjZGCwA2IrIDYAYl0grgTiciBugGIQ+9DKQwwt9XUMuRkZDBEhIWC+CFA/OmbEgsEAAPq2DAM=');
dtm_pouchL := DTMFromString('mwQAAAHic42RgYOhiZGCYDsSTgbgdiBuAuAmIW4C4G4gnAbE/EAcAcTgQRwJxGBB7A7EjEDsAsTMQ+7haAU1jwotFgCQhzEgEhgMAYt4JRg==');
dtm_pouchM := DTMFromString('mrAAAAHic42BgYEhgZGCIAeIIII4F4iwgTgfiTCCOBmJ/IPYA4kComiAg9gRiRyC2B+JgHwegKUw4sQiQxIcZCWAYAACEBQcP');
dtm_pouchS := DTMFromString('m1gAAAHic42JgYDBjZGDQB2JdILYBYgcgtgZiPSA2goobA7EfEHsBcTAQh0H5ILUuQBwK5dsDcaCXHdBUJoJYBEgSgxmJxAgAAA9OBto=');

//Checks if Astral Rune crafted in the Inventory
GameTab(tab_Inv);
MarkTime(StartTime);
while not FindDTMRotated(dtm_astral_rune, x, y, MIX1, MIY1, MIX2, MIY2, -Pi/4, Pi/4, Pi/60, extend) do
begin
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;

//finds the Altar using TPA
if not FindObjectUsingTPA(8883597, 10, 10, 20, 20, mouse_Left, ['une','une Altar','raft']) then
Output('Searching for Altar.',ElapsedTime);

wait(3000);
end;

wait(2000);
if FindDTMRotated(dtm_pouchS, x, y, MIX1, MIY1, MIX2, MIY2, -Pi/4, Pi/4, Pi/60, extend) then
begin
wait(500+random(100));
Mouse(x, y, 5, 5, mouse_Right);
wait(100+random(100));
ChooseOption('pty Small');
end;

if FindDTMRotated(dtm_pouchM, x, y, MIX1, MIY1, MIX2, MIY2, -Pi/4, Pi/4, Pi/60, extend) then
begin
wait(500+random(100));
Mouse(x, y, 5, 5, mouse_Right);
wait(100+random(100));
ChooseOption('pty Medium');
end;

if FindDTMRotated(dtm_pouchL, x, y, MIX1, MIY1, MIX2, MIY2, -Pi/4, Pi/4, Pi/60, extend) then
begin
wait(500+random(100));
Mouse(x, y, 5, 5, mouse_Right);
wait(100+random(100));
ChooseOption('pty Large');
end;

wait(800+random(200));
FindObjectUsingTPA(8883597, 10, 10, 20, 20, mouse_Left, ['une','une Altar','raft']);
wait(1000+random(500));

FreeDTM(dtm_astral_rune);
FreeDTM(dtm_pouchL);
FreeDTM(dtm_pouchM);
FreeDTM(dtm_pouchS);

Output('Altar found. Crafting runes.',0);
Antiban;
Result := True;
end;


Function TeleportToLoadstone:Boolean;
var
dtm_HomeTeleport, dtm_LoadstoneMap, x, y:Integer;
extend:Extended;
begin
FindNormalrandoms;
dtm_HomeTeleport := DTMFromString('mbQAAAHicY2VgYOBjZGAQhmIOIGYH4vNAfBmITwDxSSh735FPDLGBSxna5twA46zIAwwiQP1caJgRCwYDAGgLDdg=');
GameTab(tab_Magic);

MarkTime(StartTime);
while not FindDTMRotated(dtm_HomeTeleport, x, y, MIX1, MIY1, MIX2, MIY2, -Pi/4, Pi/4, Pi/60, extend) do
begin //Clicks the Home Teleport Icon
wait(1000 + random(200));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
Output('Home Teleport',ElapsedTime);
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
end;

FreeDTM(dtm_HomeTeleport);//Free DTM

MMouse(x,y,4,4);
wait(300 + random(200));
ClickMouse2(true);

dtm_LoadstoneMap := DTMFromString('mggAAAHicY2NgYEgF4iwgzoPSiUAcB8RzgXgalF4KxEuAeA4QK/i3M6jFTmRg1glnYNYOY1i7aAbDo+PrGUSActgwIw4MAQBbFg3z');

MarkTime(StartTime);
while not FindDTMRotated(dtm_LoadstoneMap, x, y, MSX1, MSY1, MSX2, MSY2, -Pi/4, Pi/4, Pi/60, extend) do
begin //Clicks the Lunar Isle Loadstone Map
Output('Loading Loadstones Map.',ElapsedTime);
wait(1000 + random(200));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
end;

FreeDTM(dtm_LoadstoneMap);//Free DTM

MMouse(x,y,10,10);
wait(300 + random(200));
ClickMouse2(true);
Result := True;
end;


Function Walk_LoadstoneToBank:Boolean;
var
path, TPA:TPointArray;
newPosition:TPoint;
begin
FindNormalrandoms;
SetAngle(SRL_ANGLE_HIGH);

//checks colors around Loadstone to confirm arrival
MarkTime(StartTime);
while True do
begin
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
Output('Teleporting to Loadstone',ElapsedTime);
if FindColorsSpiralTolerance(MSCX,MSCY,TPA,8166842,MSX1,MSY1,MSX2,MSY2,10) then
if FindColorsSpiralTolerance(MSCX,MSCY,TPA,10120213,MSX1,MSY1,MSX2,MSY2,10) then
begin
wait(1000 + random(500)); //Waits for Loadstone animation to complete
break;
end;
end;

wait(3000);
SPS_Setup(RUNESCAPE_SURFACE,['0_2','0_3']);
SetAngle(SRL_ANGLE_HIGH);
path := [Point(180, 975),Point(235, 970),Point(235, 950)];
Output('Walking to bank.',0);
SPS_WalkPath(path);

MarkTime(StartTime);
newPosition := SPS_GetMyPos;
while newPosition.x < 190 do
begin
wait(500+random(500));
ElapsedTime := TimeFromMark(StartTime);//How long inside loop
if(ElapsedTime > MaxRetryTimeLimit) then //Fail safe
exit;
Output('Walking to bank.',ElapsedTime);
SPS_WalkPath(path);
newPosition := SPS_GetMyPos;
end;
Result := True;
end;


Procedure AwesomeAstralCrafter;
begin
CompleteTrip := False; //Checks if the whole trip is complete.

if TeleportToLoadstone then //Home Teleport to Lunar Isle Loadstone
if Walk_LoadstoneToBank then //Walks from Loadstone to Bank
if StartBanking then //Banking Successful
if Walk_BankToAltar then //Walks from Bank To Altar
if CraftAstralRunes then //Craft Astral Runes at the Altar
CompleteTrip := True;

if not CompleteTrip then //If any steps failed
begin
FailureCount := FailureCount + 1;
if FailureCount > MaxFailureCount then //Forces the script to close after 10 failures.
ForceCloseScript := True;
if ForceCloseScript then //If maximum failures reached, exit script.
exit;
exit;
end;
end;


begin
// These 4 lines HAVE to be set BEFORE you call SetupSRL;
Smart_Server := 25;
Smart_Members := False;
Smart_Signed := True;
Smart_SuperDetail := False;

ClearDebug;
SetupSRL;
DeclarePlayers;
LoginPlayer;

Initialize; //Initialize all variables
while (SuccessTrip < MaxTrips) and (not ForceCloseScript) do
begin
AwesomeAstralCrafter;
if completeTrip then
begin
SuccessTrip := SuccessTrip + 1;
TotalEssenceCrafted := TotalEssenceCrafted + 28 + ExtraEssenceFromPouch;
end;
Proggy;
end;

Logout(); //Log outs after total trips
end.

########################################################
#############JohnBrown Astral Runecrafter###############
########################################################
Time Running: 1 Hours, 43 Seconds
Successful Trips: 28 (Limit 300)
Failed Trips: 0 (Limit 10)
Essence Crafted: 1204
########################################################
########################################################

Justin

2012-04-07 02:58:33

Would you be able to post your other scripts too?

BobboHobbo

2012-04-07 02:59:45

You seem quite talented, to write such a script, in such a short period of time of learning a new language ! But longevity is low, what are you planning to do if you become a SRL Member from this application?

Kyle Undefined

2012-04-07 03:08:30

I see a flaw with your script. It's regarding the DTMs. Can you tell me what it is?

Er1k

2012-04-07 03:15:23

From: Kyle Undefined
I see a flaw with your script. It's regarding the DTMs. Can you tell me what it is?


Interesting :) and I think I found it.

OP, can you tell us why you want to become a SRL member?

johnbrown8976

2012-04-07 03:16:27

From: Kyle Undefined
I see a flaw with your script. It's regarding the DTMs. Can you tell me what it is?


I added the missing FreeDTM function, which I forgot to free after use. Does it fix the problem?

johnbrown8976

2012-04-07 03:20:24

From: [J]ustin
Would you be able to post your other scripts too?


I have:
1. Gilded Altar with Marentill script: It walks from Yanille Bank to Yanille POH, burns the burner, and bury baby dragon bones
2. Nature runecrafting Script, walking from fairy ring bank, to fairy ring, to altar, and walking back again.

I work on weekends, so will submit Monday morning.

Er1k

2012-04-07 03:23:16

From: johnbrown8976
I could be using less number of points(Mostly 3-4),
I might be using too high tolerance(I wanted to force it to work),
I may not have used the Black boundaries as the outer points like the tutorials have suggested.
If it is none of them, I will have a longer look at the DTMs again, and reply.


It's something else. It has to do with a function.

PS. Let me interrupt before you triple post, use the edit button :)

Kyle Undefined

2012-04-07 03:25:36

From: Er1k
Interesting :) and I think I found it.

OP, can you tell us why you want to become a SRL member?


:) That's a good question too.

From: johnbrown8976
I could be using less number of points(Mostly 3-4),
I might be using too high tolerance(I wanted to force it to work),
I may not have used the Black boundaries as the outer points like the tutorials have suggested.
If it is none of them, I will have a longer look at the DTMs again, and reply.


It's not about the actual DTMs or how you made them, but the flaw is tied with your DTM logic ;)

johnbrown8976

2012-04-07 04:11:15

Removed

P1nky

2012-04-07 04:14:33

Sorry no from me, I would like to see
  • TPA's
  • RRW
  • DDTMs
  • More complex functions/procedures
  • More beautiful written failsafes
Good Luck!
-Cheers

Justin

2012-04-07 04:24:25

I am going to hold my vote as of now.
(Feel free to remove the guilded alter script as I only wanted to do some quick comparison with it)

I suggest you have another read of Kyle's posts and try to find what the flaw is and fix it :)

Best of luck!

Sin

2012-04-07 09:31:00

Two things from me, TPAs and Standards!

[XoL]

2012-04-07 10:26:17

No from me. Sorry. You are obviously smart, and capable of learning which is GREAT! but the problem I have is activity. SRL members is a community rank first, we aim to help the community so activity is key. Please work on standards, otherwise I like the script.

Try to follow this guide to become a SRL member:
http://villavu.com/forum/showthread.php?t=74195

For more advanced scripting I would suggest reading these guides: (Like tpa's)
http://villavu.com/forum/forumdisplay.php?f=96

Also one thing I really think is important is being community focused, you have 7 posts Posting actively not only shows you genuinely care for the community it also helps your chances of getting accepted.

These guides can help you with that:
http://villavu.com/forum/showthread.php?t=72050
http://villavu.com/forum/showthread.php?t=66084

Anyway, sorry for the roughness. Good luck.

rice

2012-04-07 16:40:20

No for me I would love to see tpa and check out our standards also your activity concerns me

Frement

2012-04-07 17:12:00

From: Kyle Undefined
I see a flaw with your script. It's regarding the DTMs. Can you tell me what it is?


I can't see the flaw, should I be worried? :eek:

Anyway, holding my vote for now.

johnbrown8976

2012-04-07 21:05:08

From: Sin
Two things from me, TPAs and Standards!


Thanks for the feedback. I have a question though. Which place should I use the TPAs.
-In minimap, to find distance between itself (white dot), and bank, or altar etc
-Replace the default FindDTMRotated function, and create a custom function using TPA
Or am I completely out of track?

Justin

2012-04-07 21:06:06

From: Frement
I can't see the flaw, should I be worried? :eek:

Anyway, holding my vote for now.


No, he fixed it

'Toxin

2012-04-07 21:23:10

You seem to have capability, like others have mentioned… yet… a Member status here at SRL is beyond ones scripting capability. Activity and dedication will earn you entry, in combination with your knowledge of the library and scripting capability. It's going to be a no from me… however I wish you luck in the future.

E:
However… just out of curiosity… What is it about being a Member that you want the most?

johnbrown8976

2012-04-07 21:48:40

[QUOTE='Toxin;982835]You seem to have capability, like others have mentioned… yet… a Member status here at SRL is beyond ones scripting capability. Activity and dedication will earn you entry, in combination with your knowledge of the library and scripting capability. It's going to be a no from me… however I wish you luck in the future.

E:
However… just out of curiosity… What is it about being a Member that you want the most?

To speak the truth, I misunderstood the requirement for application for SRL membership and applied for membership. I thought the requirement was just to be able to write a working well written script, which I now understand to be my complete misunderstanding.
I was reading one of the newest SRL members post who said in a post that he had to wait months to create an awesome script, and was so excited that he got accepted. So, just for curiosity, I also thought of writing a working script, and give it a try.
I apologize for my misunderstanding and trouble for the community, however, I will continue to try to contribute to the community, and one day, hopefully, after learning more advanced scripting, be a real member.

'Toxin

2012-04-07 21:54:15

No need to apologize dude, technically SRL has done it's job in teaching you the works of the library, pascal scripting, the use of Simba and utilization of plugins which have been worked on very hard by our developers who've put a LOT of time and effort for all of us to have them… And so on. We're all here to help out one another, so we'd like to see everyone doing the same thing. We're all here as a team, trying to accomplish mainly one or two common 'things', persay. So just keep at it, I actually don't doubt your ability at all, and am positive that one day, as you previously stated, you'll be a real member.

Sin

2012-04-07 22:17:54

From: johnbrown8976
Thanks for the feedback. I have a question though. Which place should I use the TPAs.
-In minimap, to find distance between itself (white dot), and bank, or altar etc
-Replace the default FindDTMRotated function, and create a custom function using TPA
Or am I completely out of track?


For my Astral Crafter, I used TPAs for object finding.

EtherFreak

2012-04-07 22:58:19

Yes from me. I like your attitude. If you dont get it this time, I would like to see more usage of TPA's.

ReadySteadyGo

2012-04-08 00:46:54

Hi johnbrown8976,

I'm voting yes, you control everything in a very clever way. However, you need to browse the tutorial section a great deal. You seem to be too comfortable with the methods you are using, they will not solve every problem. You need to be able to think further outside the box in order to grow as a SRL scripter.

I also disagree with people saying, "use TPA's". It is bad practise to think that you can just stick a bog standard TPA handling function in and that makes you SRL Member worthy. It doesn't. TPA's are useful because they give you specific control over pretty much everything. They enable you to make your script more efficient because you can get down to the raw maths behind it and manipulate them anyway you need to. There is 0 point in you using them for the sake of it, use them because for a perfect/timeless scripts they are essential.

E: I realise this sounds completely contradictory but it's tiring people voting based on whether there is a TPointArray variable in the script or not.

Er1k

2012-04-08 02:12:48

I will go with a no because you I have never seen you around until yesterday.

I am sure you are capable judging from your script, TPAs or whatnot, they don't really matter. But as others have said, it's more of a community rank rather than proving you're a scripter.

I guess you already pass for the script you have produced, you just need to participate more to earn the rank.

Good luck. I hope to see you hang around more in the forums :)

Abu

2012-04-08 19:50:02

I was so close to pushing the yes button - but then I read this on of your posts:
From: johnbrown8976
I thought the requirement was just to be able to write a working well written script, which I now understand to be my complete misunderstanding.


The problem I have with that quote is that there is no proof this script is working. I checked to see if you had released this script but you haven't, so I have seen no feedback which confirms the script is working.

For now I'm holding my vote, if you decide to implement a proggy into your script and run it for over an hour, then show us a proggy for proof - I may just vote yes.

Sir Ducksworthy

2012-04-09 07:51:48

It would probably be a yes considering your circumstances, but your the lacking Longevity which is a shame.
What you do sound's totally awesome and it sound's as if you may have some kool talent's their waiting to be unleashed on the SRL Member's forums in future! XD GL next time.

johnbrown8976

2012-04-10 01:49:40

From: abu_jwka
I was so close to pushing the yes button - but then I read this on of your posts:


The problem I have with that quote is that there is no proof this script is working. I checked to see if you had released this script but you haven't, so I have seen no feedback which confirms the script is working.

For now I'm holding my vote, if you decide to implement a proggy into your script and run it for over an hour, then show us a proggy for proof - I may just vote yes.


I thought I am not allowed to post any "Runescape Members Runecrafting Scipt" publicly on the forum. I would be glad to do so, as it would give me opportunity to know what I am doing wrong and improve upon it. I added the Proggy for one hour as you requested. I would appreciate your running/giving constructive criticism to my script, as I know you are one of the better script writers.

Abu

2012-04-10 02:43:42

From: johnbrown8976
I thought I am not allowed to post any "Runescape Members Runecrafting Scipt" publicly on the forum. I would be glad to do so, as it would give me opportunity to know what I am doing wrong and improve upon it. I added the Proggy for one hour as you requested. I would appreciate your running/giving constructive criticism to my script, as I know you are one of the better script writers.


I don't know of any such rule, but you never know.

Anyway, I'm glad you posted that proggy, it shows that your script is stable and can run for over one a half hours - which is good. Also, the fact that you haven't been here long, means you've learnt how to script fairly quickly. Which to me shows dedication and an eagerness to learn.

I voted yes, Good luck!

masterBB

2012-04-10 03:53:17

No. Becoming a SRL member is not only showing your ability to script but is also about being a community member.

Markus

2012-04-10 06:25:47

From: johnbrown8976
I thought I am not allowed to post any "Runescape Members Runecrafting Scipt" publicly on the forum. I would be glad to do so, as it would give me opportunity to know what I am doing wrong and improve upon it.


This is a common misconception, you are allowed to use any of your own scripts for your application, doesn't matter if they are private or publicly released.
Though I doubt you get in this time (already quite a few no votes) I'll leave this open for a bit of feedback.

Markus

2012-04-15 07:12:36

Closed. You may reapply in 2 weeks.