SRL Archive - Archive

zasz - SRL Member Application Form


ZaSz

2009-01-22 21:55:12

<!– BEGIN TEMPLATE: formanswers –>
zasz - SRL Member Application Form
zasz

What is the meaning to life?


Where you Referred to SRL? If yes, by whom?
no


Programming Knowledge
Learning Java, Im familiar with some windows internal commands.

Other Communitys
zaszmedia,sythe,mopar

How Long have You Played Runescape
like 4-5 years.

Are you affilated in anyway with Jagex LTD?
No
—————————————————–
Please write down a paragraph about Yourself.

I started scripting in october 2007, Made a few scripts, I try and help out on the forums when I can.

I have submitted 2-3 mems apps before, but Im very confident in this one.

Note: following script = reflection. BUT to show my use of srl usage, I added
color failsafes such as a TPA template for if reflection fails at opening bank, or mining iron.

Search function tpado to find my tpa function

I also added radialwalk and radialroadwalk, i tested by making reflectionoff := true; in the bank procedure.

Ps:Note: My script sends your players[0].nick only to my website for debug/proggies *This makes it easier then to create log files for each nick.
This script will not send your UserName, Or Password!

——————————————————
Please Post a Sample of your Work. Only SCAR Scripts Accepted


//Iron MAN 2.6!
//Start players in falador east bank.
//Script mines in the dwarven mines :)
//PICKAXE MUST BE WIELDED!


//added AddToOnlineReport - DOES NOT SEND USERNAME OR PASSWORD!!!
//Detects pick i.d's
//Reports proggies to website now.
//added colorfailsafes option. Color failsafes: Bank, mining Iron
//TPA's!!!
//Radial walk/ radial road walk!!!

program IronMan;
{.include SRL/SRL/misc/smart.scar}
{.include SRL\SRL.Scar}
{.include SRL/SRL/reflection/reflection.scar}
{.include SRL\SRL/skill/mining.Scar}

const
usecolorfailsafes = true; //If Reflection Fails - Then Do color.
plss = 6; // loads before switchin / exiting.

//How many times will you cycle through players?
howmanyloopstillquit = 2; // name says all.
funstats = 'off'; // Fun stats in proggie!!! (will add more)
showupdateproggy = 'off'; // At the beginning loop it summerizes major updates.
signq = false; // Using Smart Signed = true; Not signed = false;

// do not edit. Site login verification details
webusername = 'ironman'; //
webpassword = 'error';

var
bankpoint,srf,nearore,err,P,v : TPoint;
bankers : TPointArray;
lifeform,dd :tme;
pickid,statproggie,rca,id,ctcc,pickanim,loads,pickg,enleft,pl,d,I,smoker,ver1,ver2 : integer;
x,y,ironidopen,clay2idopen,clay1idopen,clayidclosed,ironidclosed : integer;
Tiles,Path: TPointArray;
usernick,pice,pls,plsss,checked,re : string;
reflectionoff,foundwreflection: boolean;


procedure declarePlayers;
begin
HowManyPlayers := 1;
CurrentPlayer := 0; // type the same # in the players[thisnumber].name that your starting out with
NumberOfPlayers(HowManyPlayers); // leave this alone

// ore kinds: 'iron' 'coal' 'clay'

Players[0].Name := ''; //username
Players[0].Pass := ''; //password
Players[0].Nick := '337o'; //3-4 letters from your username
Players[0].Pin := '0000'; // Your Pin for character.
Players[0].strings[1] := 'iron'; // Type of Ore
Players[0].booleans[0] := true; // Do you wish mine before going to bank at start loop?
Players[0].booleans[1] := false; // Do you wish to wet clay?
Players[0].Integers[7] := 0; // if wetting clay, how many loads till wet? 0 = 1 , 1 = 1, 2 = 2, ect.

// Players[1].Name := ''; //username
// Players[1].Pass := ''; //password
// Players[1].Nick := ''; //3-4 letters from your username
// Players[1].Pin := '0000'; // Your Pin for character.
// Players[1].strings[1] := 'iron'; // Type of Ore
// Players[1].booleans[0] := true; // Do you wish mine before going to bank at start loop?
// Players[1].booleans[1] := false; // Do you wish to wet clay?
// Players[1].Integers[7] := 0; // if wetting clay, how many loads till wet? 0 = 1 , 1 = 1, 2 = 2, ect.

// Players[2].Name := ''; //username
// Players[2].Pass := ''; //password
// Players[2].Nick := ''; //3-4 letters from your username
// Players[2].Pin := '0000'; // Your Pin for character.
// Players[2].strings[1] := 'iron'; // Type of Ore
// Players[2].booleans[0] := true; // Do you wish mine before going to bank at start loop?
// Players[2].booleans[1] := false; // Do you wish to wet clay?
// Players[2].Integers[7] := 0; // if wetting clay, how many loads till wet? 0 = 1 , 1 = 1, 2 = 2, ect.

// Players[3].Name := ''; //username
// Players[3].Pass := ''; //password
// Players[3].Nick := ''; //3-4 letters from your username
// Players[3].Pin := '0000'; // Your Pin for character.
// Players[3].strings[1] := 'iron'; // Type of Ore
// Players[3].booleans[0] := true; // Do you wish mine before going to bank at start loop?
// Players[3].booleans[1] := false; // Do you wish to wet clay?
// Players[3].Integers[7] := 0; // if wetting clay, how many loads till wet? 0 = 1 , 1 = 1, 2 = 2, ect.

end;

function areyouat(loc:string):boolean;
forward;

procedure ifnotat(loc:string);
forward;

procedure rands;
forward;

procedure smokerockfix;
forward;

function AddToOnlineReport(text: String): Boolean;
var
Site: Integer;
S: String;
begin
usernick := Players[0].Nick;
Site := InitializeHTTPClient( false, false );
ClearPostData( Site );
AddPostVariable( Site, 'report', Text);
AddPostVariable( Site, 'username', webusername);
AddPostVariable( Site, 'password', webpassword);
AddPostVariable( Site, 'ID', usernick);
S := PostHTTPPageEx ( Site, 'http://zaszmedia.freehostia.com/IronManupdate.php' );
if(S <> '') then
begin
if(S = 'Authentication Successful') then
Result:=True
else
Result:=False;
end else
Result:=False;
Writeln(S);
end;

procedure mainproggie;
begin
cleardebug;
writeln('Iron Man Version '+inttostr(ver1)+'.'+inttostr(ver2)+'');
For I := 0 To Howmanyplayers - 1 Do
begin
writeln(Players[i].nick+': Mining Lvl|'+inttostr(Players[i].Integers[0])+'| Levels advanced | '+ inttostr(Players[i].Integers[0] - Players[i].Integers[6] )+' | Loads done |'+inttostr(Players[i].Integers[1])+'| Ores Mined |'+inttostr(Players[i].integers[2])+'|');
AddToOnlineReport(Players[i].nick+': Mining Lvl|'+inttostr(Players[i].Integers[0])+'| Levels advanced | '+ inttostr(Players[i].Integers[0] - Players[i].Integers[6] )+' | Loads done |'+inttostr(Players[i].Integers[1])+'| Ores Mined |'+inttostr(Players[i].integers[2])+'|');
end;
//writeln('Total Picks on ground: '+ inttostr(pickg));
writeln('Total smoking rocks: '+ inttostr(smoker));
writeln('Total Click To Continues: '+inttostr(ctcc));
writeln('Total Time Running: ' + TimeRunning);
if funstats = 'on' then
writeln('Fun stats: Times checked for randoms |'+ inttostr(rca) +'|');
end;

// mining lvl = 0, loads = 1, ores mined = 2, pick on g = 4, gas = 5, start lvl = 6.

Procedure errorproggie;
begin
cleardebug;
mainproggie;
writeln(' ');
writeln('Iron man V '+inttostr(ver1)+'.'+inttostr(ver2));
writeln('You have recieved an error. The results of the error has been sent to my website.');
writeln('The check was: '+checked);
writeln('No need to post! I made the script send error data to my site for me to check.');
AddToOnlineReport('Nick: ' +usernick+' | the error is | P'+inttostr(err.x)+','+inttostr(err.y));
end;

Procedure statusproggie;
begin
cleardebug;
writeln('Iron Man Status Proggie!');
writeln('Current Player is: '+Players[currentplayer].Nick);
writeln('You are currently mining'+Players[currentplayer].strings[1]);
writeln('Total Time Running: ' + TimeRunning);
end;

function fctc:boolean;
begin
if FindNPCChatText('advanced a',Nothing) then
begin
mouse(335,465,10,2,true);
writeln('Advanced a lvl');
result := true;
ctcc := ctcc + 1;
Players[currentplayer].Integers[3] := Players[currentplayer].Integers[3] + 1;
end;
wait(500);
if not(GetColor(71, 464) = 14474460) then
begin
result := true;
writeln('Found a Click to continue');
mouse(335,465,10,2,true);
ctcc := ctcc + 1;
end;
end;

//Function tpado made by me
//Created By Zasz
//Easy form for tpa dev.
function tpado(color:integer;uptext:TStringArray;chooseoptiontext:string;rclick:boolean):boolean;
begin
x := MSCx;
y := MSCy;
FindColorsSpiralTolerance(x, y, bankers, color, MSx1, MSy1, MSx2, MSy2, 10);
if Length(bankers) = 0 then FindColorsSpiralTolerance(x, y, bankers, color, MSX1, MSY1, MSX2, MSY2, 10);
for i := 0 to High(bankers) do
begin
bankpoint := bankers[i]
MMouse (bankpoint.x, bankpoint.y, 3, 3);
wait(200+random(300));
if (IsUpTextMultiCustom(uptext)) then
begin
case rclick of
true: begin
result := true;
GetMousePos(x, y);
Mouse(x, y, 0, 0, False);
ChooseOption(chooseoptiontext);
Wait(500+random(250));
flag;
wait(200+random(800));
rands;
exit;
end;
false: begin
result := true;
GetMousePos(x, y);
Mouse(x, y, 0, 0, true);
flag;
wait(1000+random(800));
flag;
rands;
exit;
end;
end;
end;
end;
end;

Function there(dest:string): TPointArray;
begin;
case dest of
'top' : begin // done
SetLength(Result, 7);
Result[0] := Point(3013, 3357);
Result[1] := Point(3023, 3361);
Result[2] := Point(3033, 3367);
Result[3] := Point(3039, 3368);
Result[4] := Point(3049, 3369);
Result[5] := Point(3060, 3371);
Result[6] := Point(3061, 3376);
end;
'iron' : begin // done
SetLength(Result, 6);
Result[0] := Point(3051, 9781);
Result[1] := Point(3044, 9792);
Result[2] := Point(3043, 9800);
Result[3] := Point(3043, 9805);
Result[4] := Point(3047, 9817);
Result[5] := Point(3052, 9821);
end;
'clay' : begin // done
SetLength(Result, 5);
Result[0] := Point(3051, 9781);
Result[1] := Point(3044, 9792);
Result[2] := Point(3043, 9800);
Result[3] := Point(3043, 9805);
Result[4] := Point(3047, 9817);
Result[5] := Point(3054, 9818);
end;
'coal' : begin // done
SetLength(Result, 3);
Result[0] := Point(3050, 9780);
Result[1] := Point(3044, 9790);
Result[2] := Point(3038, 9799);
end;
'cguild' : begin // done with walking (yes im making a crafting guild addon
SetLength(Result, 13);

Result[0] := Point(3012, 3362);
Result[1] := Point(3004, 3354);
Result[2] := Point(3005, 3342);
Result[3] := Point(3005, 3329);
Result[4] := Point(3004, 3317);
Result[5] := Point(2995, 3308);
Result[6] := Point(2986, 3303);
Result[7] := Point(2975, 3301);
Result[8] := Point(2966, 3301);
Result[9] := Point(2954, 3300);
Result[10] := Point(2944, 3299);
Result[11] := Point(2936, 3295);
Result[12] := Point(2932, 3288);
end;
end;
end;

Function back(dest:string): TPointArray;
begin
case dest of
'top' : begin
SetLength(Result, 5);
Result[0] := Point(3054, 3368);
Result[1] := Point(3044, 3367);
Result[2] := Point(3038, 3357);
Result[3] := Point(3027, 3358);
Result[4] := Point(3012, 3355);
end;
'iron' : begin // done
SetLength(Result, 5);
Result[0] := Point(3047, 9813);
Result[1] := Point(3043, 9804);
Result[2] := Point(3044, 9792);
Result[3] := Point(3051, 9780);
Result[4] := Point(3057, 9777);
end;
'clay' : begin // done
SetLength(Result, 5);
Result[0] := Point(3047, 9813);
Result[1] := Point(3043, 9804);
Result[2] := Point(3044, 9792);
Result[3] := Point(3051, 9780);
Result[4] := Point(3057, 9777);
end;
'coal' : begin // done
SetLength(Result, 4);
Result[0] := Point(3043, 9796);
Result[1] := Point(3047, 9786);
Result[2] := Point(3054, 9778);
Result[3] := Point(3058, 9777);
end;
end;
end;

procedure whilemining;
begin
dd := getme;
while dd.Animation = pickanim do
begin
wait(800);
rands;
smokerockfix;
dd := getme;
end;
statproggie := statproggie + 1;
case statproggie of
1: statusproggie;
20: begin statproggie := 0; statusproggie; end;
end;
end;

procedure mines;
begin
foundwreflection := false;
case Players[currentplayer].strings[1] of
'iron' : begin
if (findobject(p,ironidopen)) and (DistanceFrom(p) < 6) then
begin
foundwreflection := true;
v := TileToMS(p, Random(5));
mouse(v.x,v.y,3,3,true);
wait(750+random(500));
rands;
end;
whilemining;
if (usecolorfailsafes = true) and (foundwreflection = false) then
begin
if tpado(2371663,['ine', 'ock'],'uick',false) then
begin
wait(600+random(500));
rands;
end;
end;
end;
'clay' : begin
if findobject(p,clay1idopen) and (DistanceFrom(p) < 4) then
begin
foundwreflection := true;
v := TileToMS(p, Random(5));
mouse(v.x,v.y,3,3,true);
r_flag;
wait(750+random(500));
rands;
end;
whilemining;
if not(R_InvFull) then
begin
if findobject(p,clay2idopen) and (DistanceFrom(p) < 4) then
begin
v := TileToMS(p, Random(5));
mouse(v.x,v.y,3,3,true);
whilemining;
wait(750+random(500));
rands;
end;
end;
if (usecolorfailsafes = true) and (foundwreflection = false) then
begin
if tpado(5939396,['ine', 'ock'],'uick',false) then
begin
wait(600+random(500));
rands;
end;
end;
end;
'coal' :
begin
if findobject(p,31070) and (DistanceFrom(p) < 6) then
begin
v := TileToMS(p, Random(5));
mouse(v.x,v.y,3,3,true);
R_flag;
wait(300+random(50));
end;
whilemining;
if not(R_InvFull) then
begin
if findobject(p,31068) and (DistanceFrom(p) < 4) then
begin
v := TileToMS(p, Random(5));
mouse(v.x,v.y,3,3,true);
whilemining;
end;
end;
end;
end;
end;

function findsmokingrock: boolean;
begin
result := false;
wait(20);
case Players[currentplayer].strings[1] of
'iron' : begin
if (findobject(p,31101)) and (DistanceFrom(p) < 2) then
result := true;
if not(findobject(p,31101)) and not(DistanceFrom(p) < 2) then
begin
if usecolorfailsafes = true then
begin
//if FindGas(x,y) then
//result := true;
end;
end;
end;
end;
end;

procedure findpchat;
//var
// S : TStringArray;
begin
// S := GetChatMessages('normal', true, False);
// writeln(s[0]);
end;

procedure rands;
begin
R_FindRandoms;
findnormalrandoms;
//if FindPick then
//begin
//writeln('Picks on ground, fixed');
//pickg := pickg + 1;
//end;
fctc;
findpchat;
rca := rca + 1;
end;

function invisrfull:boolean;
begin
if R_InvFull then
begin
result := true;
writeln('Your inventory is full, Banking.');
end;
end;


procedure opendoor;
begin
if findobject(p,11714) and (DistanceFrom(p) < 6) then
begin
v := TileToMS(p, Random(5));
mouse(v.x,v.y-30,3,3,true);
flag;
wait(2000+random(1000));
end;
end;

procedure climbstair(dir:string);
begin
case dir of
'up' : begin
if findobject(p,30943) then
begin
v := TileToMS(p, Random(5));
mouse(v.x,v.y,3,3,true);
flag;
wait(700+random(1000));
end;
end;
'down' : begin
if findobject(p,35921) then
begin
v := TileToMS(p, Random(5));
mouse(v.x,v.y,3,3,true);
flag;
wait(700+random(1000));
end;
end;
end;
end;

procedure walkback;
begin
enleft := GetMMLevels('run',re);
if enleft > 35 then
begin
setrun(true);
end;
rands;
//walkfrom(ores);
Path := back(Players[currentplayer].strings[1]);
for i := 0 to High(Path) do
Begin
WalkToTile(Path[i], 1, 1);
R_Flag;
rands;
wait(550+random(300));
end;
climbstair('up');
rands;
wait(1500+random(1000));
ifnotat('shouse')
opendoor;
rands;
Path := back('top');
for i := 0 to High(Path) do
Begin
WalkToTile(Path[i], 1, 1);
R_Flag;
rands;
wait(550+random(300));
end;
end;

procedure walkthere;
begin
//reflectionoff := true;
enleft := GetMMLevels('run',re);
if enleft > 35 then
begin
setrun(true);
end;
Path := there('top');
if not(reflectionoff) then
for i := 0 to High(Path) do
Begin
WalkToTile(Path[i], 1, 1);
R_Flag;
rands;
wait(550+random(300));
end;
if reflectionoff then
begin
RadialRoadWalk(6123637, 70, 100, 65, -1, 0);
wait(200+random(100));
flag;
RadialRoadWalk(6123637, 75, 100, 65, -1, 0);
wait(200+random(100));
flag;
RadialRoadWalk(6123637, 25, 100, 65, -1, 0);
wait(300+random(50));
RadialWalk(9153455, 40, 100, 65, -1, 0);
end;
ifnotat('shouse')
opendoor;
rands;
climbstair('down');
rands;
wait(1500+random(1000));
Path := there(Players[currentplayer].strings[1]);
for i := 0 to High(Path) do
Begin
WalkToTile(Path[i], 1, 1);
R_Flag;
rands;
wait(550+random(300));
end;
rands;
//walkto(ores);
setrun(false);
end;

procedure banked;
begin
if not(R_InvEmpty) then
begin
OpenBankReflection('feb');
R_Flag;
if PinScreen then InPin(Players[CurrentPlayer].Pin);
wait(500+random(1000));
depositall;
wait(1000+random(2000));
closebank;
wait(1000+random(500));
rands;
end;
if usecolorfailsafes = true then
begin
if (InvCount > 0) then
begin
if tpado(4349814,['ank', 'ooth'],'uick',true) then
begin
writeln('Opened Bank');
if PinScreen then InPin(Players[CurrentPlayer].Pin);
wait(500+random(1000));
depositall;
wait(1000+random(2000));
mouse(489,35,4,4,true);
wait(1000+random(500));
end else
begin
writeln('Couldn''t open the bank!!!');
end;
end;
end;
end;

procedure smokerockfix;
begin
if findsmokingrock then
begin
writeln('Found Smoking rock, waiting');
smoker := smoker + 1;
srf := GetMyPos;
srf := TileToMS(srf, Random(5));
mouse(srf.x-1,srf.y,3,3,false);
wait(100+random(200));
R_Chooseoption('ere');
repeat
wait(50);
until not(findsmokingrock) ;
end;
end;

procedure mineloop;
begin
//writeln(inttostr(dd.Animation));
whilemining;
mines;
dd := getme;
wait(750+random(120));
end;

procedure wetclay;
begin
end;

function areyouat(loc:string):boolean;
begin
lifeform := getme;
case loc of
'iron' : begin
err := Point(3051, 9820);
err := TileToMM(err);
if rs_OnMiniMap(err.x,err.y) then
begin
result := true;
end;
end;
'clay' : begin
err := Point(3051, 9820);
err := TileToMM(err);
if rs_OnMiniMap(err.x,err.y) then
begin
result := true;
end;
end;
'coal' : begin
err := Point(3038, 9799);
err := TileToMM(err);
if rs_OnMiniMap(err.x,err.y) then
begin
result := true;
end;
end;
'bank' : begin
err := Point(3012, 3356);
err := TileToMM(err);
if rs_OnMiniMap(err.x,err.y) then
begin
result := true;
end;
end;
'shouse' : begin
err := Point(3061, 3376);
err := TileToMM(err);
if rs_OnMiniMap(err.x,err.y) then
begin
result := true;
reflectionoff := false;
end;
end;
end;
end;

procedure ifnotat(loc:string);
begin
if not(areyouat(loc)) then
begin
err := GetMyPos;
checked := loc;
errorproggie;
terminatescript;
end;
end;

procedure findfix(des:string);
begin
rands;
case des of
'bank': begin
if not areyouat(des) then
begin
if areyouat(Players[currentplayer].strings[1]) then
begin
if (Players[currentplayer].booleans[0] = true) and not(invisrfull) then
begin
repeat
findfix(Players[currentplayer].strings[1]);
ifnotat(Players[currentplayer].strings[1]);
gametab(4);
rands;
wait(2000);
mineloop;
until (invisrfull);
end;
walkback;
end;
if areyouat('shouse') then
begin
opendoor;
flag;
wait(700+random(500));
path := back('top');
for i := 0 to High(Path) do
Begin
WalkToTile(Path[i], 1, 1);
R_Flag;
rands;
wait(550+random(300));
end;
end;
end;
end;
Players[currentplayer].strings[1] : begin
if not areyouat(des) then
begin
if areyouat('bank') then
begin
walkthere;
end;
if areyouat('shouse') then
begin
opendoor;
R_Flag;
climbstair('down');
wait(700+random(500));
path := there('bottom');
for i := 0 to High(Path) do
Begin
WalkToTile(Path[i], 1, 1);
R_Flag;
rands;
wait(550+random(300));
end;
end;
end;
end;
end;
end;

procedure mloop;
begin
repeat
gametab(4);
findfix('bank');
ifnotat('bank');
banked;
enleft := GetMMLevels('run',re);
walkthere;
repeat
findfix(Players[currentplayer].strings[1]);
ifnotat(Players[currentplayer].strings[1]);
gametab(4);
rands;
wait(2000);
mineloop;
until (invisrfull);
//writeln('inv full');
DumpSettingArray;
walkback;
banked;
Players[currentplayer].Integers[0] := getskillinfo('mining',false);
Players[currentplayer].Integers[1] := Players[currentplayer].Integers[1] + 1;
Players[currentplayer].Integers[2] := Players[currentplayer].Integers[2] + 28;
mainproggie;
if Players[currentplayer].booleans[1] = true then
begin
if (Players[currentplayer].Integers[1] = Players[currentplayer].Integers[7]) or (Players[currentplayer].Integers[7] = 0) then
begin
wetclay;
end;
end;
until Players[currentplayer].Integers[1] = plss;
end;

procedure welcomeproggie;
begin
cleardebug;
usernick := Players[currentplayer].Nick;
writeln('Welcome to Iron Man V '+inttostr(ver1)+'.'+inttostr(ver2)+'!');
if showupdateproggy = 'on' then
begin
writeln('Current fixes: 3. Addons 1.');
writeln('Fixes:');
writeln('Fixed walk there error.');
writeln('Smoking rock fixed.');
writeln('Tiny fixes (as always).');
writeln('Addons:');
writeln('Smoking rock detection (fix/addon)');
writeln('For More Info on updates go to the SRL Thread');
//writeln('You have set the script to mine '+ plsss) // work in action - expect in later version
end;
end;

procedure setpintegers; //trying to make my own for d := 0 to 5 didnt work. Sorry about the repition
begin
i := 0;
d := 0;
repeat
d := 0;
Players[i].Integers[D] := 0; //0
d := d + 1;
Players[i].Integers[D] := 0; //1
d := d + 1;
Players[i].Integers[D] := 0; //2
d := d + 1;
Players[i].Integers[D] := 0; //3
d := d + 1;
Players[i].Integers[D] := 0; //4
d := d + 1;
Players[i].Integers[D] := 0; //5
d := d + 1;
Players[i].Integers[D] := 0; //6
d := d + 1;
Players[i].Integers[D] := 0; //7

Players[i].Active := True;
i := i + 1;
until i = howmanyplayers;
end;

function hasavalidpick:boolean;
begin
pice := 'love';
wait(200+random(300));
if (pickid > 1260) and (pickid < 1280) then
begin
result := true;
pice := 'off';
case pickid of
1266 : begin result := false; pice := 'on'; end; // Bronze pick
1268 : begin result := false; pice := 'on'; end; // Iron pick
1270 : begin result := false; pice := 'on'; end; // Steel pick
1274 : begin result := false; pice := 'on'; end; // Mith pick
1272 : begin result := false; pice := 'on'; end; // Adam pick
1276 : begin result := false; pice := 'on'; end; // Rune pick
end;
end;
end;

procedure picksetup;
begin
pickid := GetIDEquippedAt(3);
//writeln(pickid);
if (hasavalidpick) and (pice = 'off') then
begin
AddToOnlineReport(inttostr(pickid)); // sends pick id if not here
writeln('The pick you are weilding has been added to the log, please wait');
writeln('For up to 24 hours for the pick to be added to the script.');
end;
case pickid of
1266 : pickanim := 625; // bronze pick
1268 : pickanim := 624; // iron pick
1270 : pickanim := 624; // steel pick
1274 : pickanim := 629; // mithril pick
1272 : pickanim := 624; // adam pick
1276 : pickanim := 624; // rune pick
end;
end;

procedure oresetup(ore:string);
begin
case ore of
'tin' : begin end;
'copper' : begin end;
'clay' : begin clay1idopen := 31063; clay2idopen := 31062; clayidclosed := 0; end;
'iron' : begin ironidopen := 31071; ironidclosed := 0; end;
'coal' : begin end;
'gold' : begin end;
'mithril' : begin end;
'adamant' : begin end;
end;
end;

procedure setupversion;
begin
ver1 := 2;
ver2 := 5;
end;

function playerl(opt:string):boolean;
begin
case opt of
'calc' : begin
pls := inttostr(pl);
plsss := inttostr(plss);
end;
'sub' : pl := pl - 1;
'done' : begin
if pl = 0 then
result := true;
end;
end;
end;


procedure setups;
begin
pl := HowManyPlayers;
pl := pl * howmanyloopstillquit;
SMARTSetupEx(113, False, signq, False);
Settargetdc(smartgetdc);
setupsrl;
SetupMining;
declareplayers;
setpintegers;
cleardebug;
loginplayer;
wait(400+random(1000));
setangle(true);
setupversion;
playerl('calc');
welcomeproggie;
end;

begin
//DumpSettingArray;
setups;
repeat
picksetup;
oresetup(Players[currentplayer].strings[1]);
rands;
Players[currentplayer].Integers[6] := getskillinfo('mining',false);
loads := 0;
mloop;
playerl('sub');
nextplayer(true);
until playerl('done');
end.

——————————————————
<!– END TEMPLATE: formanswers –>

Ejjman

2009-01-22 22:25:19

-Code isn't very nice to look at, but nothing is wrong with that.
-I love you how you store stats into players.integer[x], because it is great to take use of them.
-'tpado' is a funny name for a proc, but it's good for your own.
-I'm not familiar with reflection, but it looks like you are monitoring your location and the rocks well and keeping yourself up to date on everything.
-function isinvfull is redundant. Wherever it is used, just place r_InvFull.
-A little use of Radial Road Walk
-If it fails opening the bank, all you did was a writeln. I know you are almost positive it won't fail, but just be careful…;)
-procedure wetclay =…? Hehe
-procedure/function ifnotat(blah), please at least slap a next player in there, or make him log out. Don't just terminate the script!
-I do prefer the scripting style you have seperating stuff into loops, like your main loop, randoms procedure loop, while mining, etc.
-use an array to set integers in setpintegers; procedure


Overall
I am not a fan of Reflection, but it is the current scripting style and I see that you have knowledge on how to do it. I think that you could make a script that I would use and trust.

I hope you work on things/explain the things above, and I hope you get in and keep scripting.

yes

lordsaturn

2009-01-22 22:42:42

Looks good, nice color-reflection hybrid. :)

Btw, all of this code:

SetLength(Result, 6);
Result[0] := Point(3051, 9781);
Result[1] := Point(3044, 9792);
Result[2] := Point(3043, 9800);
Result[3] := Point(3043, 9805);
Result[4] := Point(3047, 9817);
Result[5] := Point(3052, 9821);
can be done in one line.

Result := [Point(3051, 9781), Point(3044, 9792), Point(3043, 9800), Point(3043, 9805), Point(3047, 9817), Point(3052, 9821)];

I vote yes.

Runescapian321

2009-01-22 22:53:20

Yesh! You're pretty active and helpful + the script seems to fulfill most of the requirements and you clearly show your knowledge of scripting :)

Ejjman

2009-01-22 23:06:14

From: lordsaturn
Looks good, nice color-reflection hybrid. :)

Btw, all of this code:

SetLength(Result, 6);
Result[0] := Point(3051, 9781);
Result[1] := Point(3044, 9792);
Result[2] := Point(3043, 9800);
Result[3] := Point(3043, 9805);
Result[4] := Point(3047, 9817);
Result[5] := Point(3052, 9821);
can be done in one line.

Result := [Point(3051, 9781), Point(3044, 9792), Point(3043, 9800), Point(3043, 9805), Point(3047, 9817), Point(3052, 9821)];

I vote yes.


All code can be done in one line.
It's a matter of how you like to view your code. Stretched, or, in your case, squashed. :)

Kyle Undefined

2009-01-22 23:08:03

Yes! Your script looks very good. I do agree with Ejjman about your code is kinda hard to read, but everybody has their own style of scripting that makes it easier for them. You do show that you know how to script and know SRL. I hope you get in this time, keep up the good work ;)

P.s. I love your online reporter :D

~Camo

Scaper

2009-01-23 01:07:14

yes definastlyu looking goood i can see were this is going

auto yes i say

benjaa

2009-01-23 07:06:39

yes

looks good, i may sound like im just saying it but i had a good look through it
it's late, so i cbb looking at specifics again

some failsafes could be improved (mostly after else) but its really good otherwise

reflection is not easy to grasp

Sir R. M8gic1an

2009-01-23 07:38:05

I've had a look through the script, and it doesn't look bad.
You've applied a few times which shows determination.
As Ejjman said - it is rather hard for me to read, - maybe if you spaced things more it would also be easier for you to read?

and I especially loved this:

const
usecolorfailsafes = true; //If Reflection Fails - Then Do color.

A script that uses both reflection and color. I think that for that you totally deserve members because you are going in the right direction, using both.

~RM

Dervish

2009-01-23 13:21:03

Yes.

Grade :
85/100

Ejjman

2009-01-23 15:09:07

From: Dr D. Dervish
Yes.

Grade :
85/100


Just a note:
He has no idea why he lost 15 points/you gave him the 85 points. Overall, useless post for him.

Dervish

2009-01-23 15:37:45

From: Ejjman1
Just a note:
He has no idea why he lost 15 points/you gave him the 85 points. Overall, useless post for him.


Personal preferences.

Sir R. M8gic1an

2009-01-23 16:26:55

From: Dr D. Dervish
Personal preferences.


he is just as clueless as before.

~RM

Ejjman

2009-01-23 16:36:30

From: Rasta Magician
he is just as clueless as before.

~RM


Hehe. That's like saying 'That girl is hot! 85/100!', and your friend is like, 'why the 15 down?' Personal preference. Hahaha, not much sense at all.

Wizzup?

2009-01-23 20:19:28

No. Sorry.
This shows you have knowledge of reflection, not of SRL.
I see no Object Finding TPA, no RadialWalk, and no DTM's.

I thought there was a golden rule 'No Reflections Appliances'?
E: I see some 'Color FailSafes', but I doubt the script will work with the just the fail safes.
The script is mainly reflection, and I thought we never counted Reflection in Member scripts?

ZaSz

2009-01-23 20:31:29

Ummm wizzup? Do ctr f I even told you what to seach for to see my tpa function… And to others ty for the input.I will update my script in after I get mems.

Wizzup?

2009-01-23 20:58:57

From: zasz
Ummm wizzup? Do ctr f I even told you what to seach for to see my tpa function… And to others ty for the input.I will update my script in after I get mems.


I've seen the tpado.
Adding failsafes doesn't show SRL knowledge.

Ejjman

2009-01-23 21:33:28

I was unaware of this 'golden rule' as I have thought times have changed, but I haven't been involved in the community lately.

Your failsafes will not work alone.

Dervish

2009-01-24 04:54:53

What ? If I had said :

Yes.


Yet, many people say that and they don't get this kind of discussion.

Let's forget about it then.

Preferences :

Reflection < SRL

benjaa

2009-01-24 04:59:01

dammit, i didnt know 'golden rule' either

bugger, ahh well..

jakeyboy29

2009-01-24 06:49:12

From: Camo¤Kyle
Yes! Your script looks very good. I do agree with Ejjman about your code is kinda hard to read, but everybody has their own style of scripting that makes it easier for them. You do show that you know how to script and know SRL. I hope you get in this time, keep up the good work ;)

P.s. I love your online reporter :D

~Camo


agreed, btw camo when did members?

Naum

2009-01-24 07:24:09

Yes, Very good script. I was going to make a thread in the Members Section for you to be a member anyways, but it seems you've already applied :).

Gu3st...

2009-01-26 15:31:15

From: Wizzup?
No. Sorry.
This shows you have knowledge of reflection, not of SRL.
I see no Object Finding TPA, no RadialWalk, and no DTM's.

I thought there was a golden rule 'No Reflections Appliances'?
E: I see some 'Color FailSafes', but I doubt the script will work with the just the fail safes.
The script is mainly reflection, and I thought we never counted Reflection in Member scripts?

Agreed. I vote no.. Sorry

Raskolnikov

2009-01-27 15:08:28

No.

You have a fatal error, correct me if I am wrong but in your multiplayer, you have no

Players[0].Active := True;

I don't think would compile.

You know reflection very well, but you need to have a greater understanding of color (dtms etc.)

I would have voted yes but the attitude towards Wizzup? was immature.

Overall:

Come back next month and it is a yes from me:

40/100

Cut em2 it

Kyle Undefined

2009-01-27 16:11:26

From: jakeyboy29
agreed, btw camo when did members?


12-11-2008, 04:57 PM ;)

I didn't know about the no reflection scripts. :/

~Camo

ZaSz

2009-01-27 17:03:04

From: Cut em2 it
No.

You have a fatal error, correct me if I am wrong but in your multiplayer, you have no

Players[0].Active := True;

I don't think would compile.

You know reflection very well, but you need to have a greater understanding of color (dtms etc.)

I would have voted yes but the attitude towards Wizzup? was immature.

Overall:

Come back next month and it is a yes from me:

40/100

Cut em2 it


I didn't mean to be rude to Wizzup? (sorry if i sounded rude).

Thanks for the input also, but actually. the Players[0].Active := True; is in the setpintegers; procedure :) I thought it would just go there since if someone wanted to start there players false, they could just // the player out am I right?

Also My next version, after the final decision of me becoming mems, I was going to work on making the script only making color updates/addons.

Gu3st...

2009-01-27 17:06:46

From: zasz
Thanks for the input also, but actually. the Players[0].Active := True; is in the setpintegers; procedure :) I thought it would just go there since if someone wanted to start there players false, they could just // the player out am I right?

No, not correct, if you comment out the player then SCAR would not read the lines as code, but as comments.

ZaSz

2009-01-27 17:08:32

sorry if i was unclear but false means the player wouldn't even play, so i was saying just comment them out if you dont want them used.

Gu3st...

2009-01-27 17:14:55

From: zasz
sorry if i was unclear but false means the player wouldn't even play, so i was saying just comment them out if you dont want them used.
But then you would have to edit the HowManyPlayers and every index after the player you want to not to use… Easier to just set the player to False ;)

EDIT: But I do understand what you mean, there is a tiny bit of logic there..

Shuttleu

2009-01-27 17:27:58

no
i dont agree with reflection being in member apps as it makes to code too easy
you need to show that you can use SRL not reflection
any noob can use reflection if he spends about 5-10 minuites looking at it
this should really be done in color and as it is not i voted no
please show us you know how to code in COLOR and you know how to use SRL properly
im sorry if i sound harsh but everyone else has to do theirs in color so why should you be different?

~shut

mixster

2009-01-29 14:43:31

SetPInteger:
for loop, as you said you wanted to use, should work fine:

for i := 0 to HowManyPlayers - 1 do
begin
Players[i].Active := True;
for d := 0 to 7 do
Players[i].Integers[d] := 0;
end;

function Playerl doesn't need to be a function or be as compact since its result isn't set except for one case - instead it should be split into a procedure and a function.

Your OreSetup procedure seems to be a bit empty with case options that have no code to go along with them that should be removed. Also, since it will always be used for the current player, it would make more sense to have it take no arguments and just Players[CurrentPlayer] etc. for the case.

In FindFix, it seems you could simplify it a lot. By making a GetMyLoc (or similar) function, you could make it return "iron" or "clay" etc. then "error" or something if it's not at a set place. This would mean that you could then use this in a case to get you where you need to, ie (when you are supposed to be at the bank) case GetMyLoc of 'iron': WalkToBank; If you didn't want to implement this, then there are a few if's that you should turn into else if's.

In the mines procedure, you should use an if() else if() for the reflection search then colour search for logic reasons since it should look for it with reflection but if it fails then search for colour - the WhileMining procedure should then incorporate a colour/non reflection failsafe for mining. You could probably also cut down on code by creating a variable to hold what it should be looking for, ie var oreToMine, then use that in a single FindObject with a standard method of clicking to mine it, waiting for it to stop mining and then a standard check - it would make it much easier to read and make it look nicer.

In HasAValidPick, you can simplify the case since you can tell it to run the same command if it matches several options into:
case pickid of
1266, 1268, 1270, 1272, 1274, 1276: result := false; pice := 'on';
The same can be done in PickSetup to group the Iron, Steel, Addy and Rune animations.

For the walking itself, you don't so much have a colour failsafe as a colour alternative - neither can successfully fix themselves, so neither is a failsafe. You make sure to check you are in the right place, but as you don't check to see if you could get to the right place before killing the script, it can't be said to be reliable. The reflection itself will most likely not fail as long as the hooks are correct, but the colour should have some form of checking it is on track.

FCTC could use a check in the case that the level up unlocks new abilities and the like, ie "You got level x magic" then after clicking it turns into "You can now castrate chickens using wind blast".

Those are a few points of improvement. Otherwise, the script shows potential. Though not as complete as it appears it will be, there is a lot of room for growth, which a couple of empty procedures give away. The logic is spot on nearly always with a couple of bits seeming to make no sense but upon closer inspection they do (could be an area of improvement to try and make the flow of the script easier to understand). I would also like to suggest using camel cases when naming procedures and functions to make them a little easier to read as well as perhaps better names to give them more meaning, ie FCTC only revealed what it was upon checking the procedures insides.

I wish you good luck with the future of the script :)

ZaSz

2009-01-29 20:12:40

From: mixster
SetPInteger:
for loop, as you said you wanted to use, should work fine:

for i := 0 to HowManyPlayers - 1 do
begin
Players[i].Active := True;
for d := 0 to 7 do
Players[i].Integers[d] := 0;
end;

function Playerl doesn't need to be a function or be as compact since its result isn't set except for one case - instead it should be split into a procedure and a function.

Your OreSetup procedure seems to be a bit empty with case options that have no code to go along with them that should be removed. Also, since it will always be used for the current player, it would make more sense to have it take no arguments and just Players[CurrentPlayer] etc. for the case.

In FindFix, it seems you could simplify it a lot. By making a GetMyLoc (or similar) function, you could make it return "iron" or "clay" etc. then "error" or something if it's not at a set place. This would mean that you could then use this in a case to get you where you need to, ie (when you are supposed to be at the bank) case GetMyLoc of 'iron': WalkToBank; If you didn't want to implement this, then there are a few if's that you should turn into else if's.

In the mines procedure, you should use an if() else if() for the reflection search then colour search for logic reasons since it should look for it with reflection but if it fails then search for colour - the WhileMining procedure should then incorporate a colour/non reflection failsafe for mining. You could probably also cut down on code by creating a variable to hold what it should be looking for, ie var oreToMine, then use that in a single FindObject with a standard method of clicking to mine it, waiting for it to stop mining and then a standard check - it would make it much easier to read and make it look nicer.

In HasAValidPick, you can simplify the case since you can tell it to run the same command if it matches several options into:
case pickid of
1266, 1268, 1270, 1272, 1274, 1276: result := false; pice := 'on';
The same can be done in PickSetup to group the Iron, Steel, Addy and Rune animations.

For the walking itself, you don't so much have a colour failsafe as a colour alternative - neither can successfully fix themselves, so neither is a failsafe. You make sure to check you are in the right place, but as you don't check to see if you could get to the right place before killing the script, it can't be said to be reliable. The reflection itself will most likely not fail as long as the hooks are correct, but the colour should have some form of checking it is on track.

FCTC could use a check in the case that the level up unlocks new abilities and the like, ie "You got level x magic" then after clicking it turns into "You can now castrate chickens using wind blast".

Those are a few points of improvement. Otherwise, the script shows potential. Though not as complete as it appears it will be, there is a lot of room for growth, which a couple of empty procedures give away. The logic is spot on nearly always with a couple of bits seeming to make no sense but upon closer inspection they do (could be an area of improvement to try and make the flow of the script easier to understand). I would also like to suggest using camel cases when naming procedures and functions to make them a little easier to read as well as perhaps better names to give them more meaning, ie FCTC only revealed what it was upon checking the procedures insides.

I wish you good luck with the future of the script :)


dude ty for all that input, and all those idea's! I will be sure to use those suggestions. did you not vote because you were going to say no?

Dracody

2009-01-29 20:22:24

From: Rasta Magician
I've had a look through the script, and it doesn't look bad.
You've applied a few times which shows determination.
As Ejjman said - it is rather hard for me to read, - maybe if you spaced things more it would also be easier for you to read?

and I especially loved this:

const
usecolorfailsafes = true; //If Reflection Fails - Then Do color.

A script that uses both reflection and color. I think that for that you totally deserve members because you are going in the right direction, using both.

~RM


I totally agree With RM, its nice and its such a big Kind of Failsafe for if reflection Fails. :)

You are in, Yes!

Hobbit

2009-01-29 23:43:31

Poll has closed

18 yes
8 no

Welcome to SRL Members :)