SRL Archive - RS3 Help

simple and silly


GRIM

2014-12-13 17:35:54

Can anyone help me out

i want my progress report to permanently print in the debug below

procedure progressReport;
begin

XP := (chatBox.getXPBar - startingXP);
XPH := round(XP * (3600.0 / (getTimeRunning / 1000.0)));
loadsPH := round((loadsDone * (3600.0 / (getTimeRunning / 1000.0))));

writeLn('|===========================================================|');
writeLn('| GRIM TRANSMUTATION |');
writeLn('|===========================================================|');
writeLn(padR('| Running For: ' + timeRunning, 60) + '|');
writeLn(padR('| Loads done: ' + groupDigits(loadsDone, ','), 40) + padR('Loads/H: ' + groupDigits(loadsPH, ','), 20) + '|');
writeLn(padR('| Exp Earned: ' + groupDigits(XP, ','), 40) + padR('Exp/Hour: ' + groupDigits(XPH, ','), 20) + '|');
writeLn('|___________________________________________________________|');
writeLn('|___________________________________________________________|');

end;

how would I go about this?

in my mainloop i have it

clearDebug();
progressReport();

after everything essentially and it keeps it printed in the debug box
is there a simpler way to have this print permanently to the debug ? so i can free up 15+ lines?

Lipcot

2014-12-13 17:37:48

From: GRIM


i dont understand.. if you are doing cleardebug and then progress report then the only thing you have is proggy, what do you mean with permanently?

maybe you are looking for this?

DisableSRLDebug := True;

GRIM

2014-12-13 17:54:18

From: undorak7
i dont understand.. if you are doing cleardebug and then progress report then the only thing you have is proggy, what do you mean with permanently?

maybe you are looking for this?

DisableSRLDebug := True;


if I do this will it disable everything that's in the debug except for my
writeLn('ssss');

akarigar

2014-12-13 18:45:47

From: GRIM
if I do this will it disable everything that's in the debug except for my
writeLn('ssss');


It will get rid of all the SRL debug, so yes.

KeepBotting

2014-12-13 19:01:24

The only way to have the progress report permanently in the debug box is to disable all other debug.

So disableSrlDebug as others have said, and remove all your writeLn()s

That's not exactly viable, so what you can do is make all your writeLn()s conditional, so you can enable/disable them at will

Declare something like this up at the top where you define SMART, SRL-6, SPS-RS3 and the like
{$define debug_on} //delete this to disable the script's debug output 

Then place a function such as this in your script:
procedure writeDebug(text:string);
begin
{$ifdef debug_on}
writeLn('[DEBUG] : ' + text);
{$endif}
end;

Then change every writeLn() in the script to writeDebug() or whatever you name it - except the progress reports! Keep them as writeLn()

Then, you can comment out the new $define to disable all debug sans progress report, and enable it if you need the debug back

akarigar

2014-12-13 22:11:46

From: KeepBotting
The only way to have the progress report permanently in the debug box is to disable all other debug.

So disableSrlDebug as others have said, and remove all your writeLn()s

That's not exactly viable, so what you can do is make all your writeLn()s conditional, so you can enable/disable them at will

Declare something like this up at the top where you define SMART, SRL-6, SPS-RS3 and the like
{$define debug_on} //delete this to disable the script's debug output 

Then place a function such as this in your script:
procedure writeDebug(text:string);
begin
{$ifdef debug_on}
writeLn('[DEBUG] : ' + text);
{$endif}
end;

Then change every writeLn() in the script to writeDebug() or whatever you name it - except the progress reports! Keep them as writeLn()

Then, you can comment out the new $define to disable all debug sans progress report, and enable it if you need the debug back


Another option would be to use print instead of writeLn for logging/debugging. This way the debug info will still get logged into your logs folder, but it won't be shown in Simba.