Log in

View Full Version : Progress report.



Laimonas171
08-29-2009, 07:39 PM
Can anyone show good and easy tut about progress reports. or show simple how to do. I quick understood it. don't need very intermediate example.

code for exampe.


program FM;
{.include SRL/SRL/Misc/Smart.scar}
{.include SRL/SRL.scar}
{.include SRL/SRL/skill/Firemaking.scar}
{.include SRL/SRL/misc/Reports.scar}

Procedure DeclarePlayers;
begin
HowManyPlayers := 1;
CurrentPlayer := 0;
NumberOfPlayers(HowManyPlayers);
Players[0].Name := 'Yxxxx'; //Username
Players[0].Pass := 'ssss'; //Password
Players[0].Nick := 'xxxx'; //sern
Players[0].Active := true; //leave it
Players[0].BoxRewards := ['XP', 'ostume', 'oins', 're']; //reward from randoms
end;

Procedure forExampleBankFind;
var x, y: integer;
begin
if FindSymbol(x, y, 'bank') then
begin
Mouse(X, Y, 5, 5, True);
FFlag(0)
end;
end;

Procedure Proggy;
begin
ClearDebug;
WriteLn('Bank symbols finds: ' + bankfinds); // or something like that.
WriteLn('Worked for: ' + Hours + ':' + Minutes + ':' + Seconds + '.')
end;
Procedure MainLoop;
begin
ForexampleBankFind;
Proggy;
end;
Begin
SetupSRL;
DeclarePlayers;
LoginPlayer;
ClearDebug;
MainLoop;
end.

Rich
08-29-2009, 07:46 PM
procedure Proggy;
begin
ClearDebug;
WriteLn('//////////////////////////|\\\\\\\\\\\\\\\\\\\\\\\\\\');
WriteLn('Laimonas171''s Bank Symbol Finder');
WriteLn('Found ' + IntToStr(BankFinds) + ' bank symbols');
WriteLn('Worked for ' + TimeRunning);
end;

Something like that?

Richard.

Sir R. M8gic1an
08-29-2009, 07:46 PM
Tutorial Island -> Newly Added to SRL -> Reports.scar

~RM

Laimonas171
08-29-2009, 07:47 PM
procedure Proggy;
begin
ClearDebug;
WriteLn('//////////////////////////|\\\\\\\\\\\\\\\\\\\\\\\\\\');
WriteLn('Laimonas171''s Bank Symbol Finder');
WriteLn('Found ' + IntToStr(BankFinds) + ' bank symbols');
WriteLn('Worked for ' + TimeRunning);
end;

Something like that?

Richard.
Yes just i dont know how to increase numbers.

EDIT: i am sure what need to make variables and add then after procedures then use them on proggy somehow. can you edit my code in first post and add simple time and symbols finds ?

Rich
08-29-2009, 07:53 PM
Ok, have a variable called BankFindsvar
BankFinds : Integer;

When it finds a bank symbol, you want to increase that by one. There are two ways of doing this.

procedure ForExampleBankFind;
var
X, Y : Integer;

begin
if FindSymbol(X, Y, 'bank') then
begin
BankFinds:= BankFinds + 1; //This is the first way
Mouse(X, Y, 5, 5, True);
FFlag(3);
end;
end;

Or this:

procedure ForExampleBankFind;
var
X, Y : Integer;

begin
if FindSymbol(X, Y, 'bank') then
begin
Inc(BankFinds); //And this is the seconds way of increasing BankFinds by 1
Mouse(X, Y, 5, 5, True);
FFlag(3);
end;
end;

Hope I helped,
Richard

Laimonas171
08-29-2009, 07:58 PM
yes you do ty vm. Rep++ :)

Rich
08-29-2009, 07:59 PM
Oooo, thanks. If you need any more help with anything, feel free to PM me and I'll see what I can do.