I have a script with a case random of 100 and it runs until false.
Every time the case lands on something it reports to console, I'd like to know what landed. Is there a way to save debug to file every set amount of time or cases ?
I have a script with a case random of 100 and it runs until false.
Every time the case lands on something it reports to console, I'd like to know what landed. Is there a way to save debug to file every set amount of time or cases ?
Take a look at the MSI Include. I know they have a way of doing this with their scripts.
Simply a GOD beast...
My Tutorials
I found this months ago. Didnt try it out yet.
Simba Code:function WriteReportToFile: Boolean;
var
theFile: Integer;
thePath: string;
begin
thePath := AppPath + 'Scripts\Progress.txt';
try
theFile := RewriteFile(thePath, False);
except
Writeln('Error opening file!');
end;
WriteFileString(theFile, 'Tree: ' + TreeName + #13 + #10); // The '#13 + #10' will skip to the next line in the file, so Exp: won't be written on the same line
WriteFileString(theFile, 'Exp: ' + FloatToStr(TreeExp) + #13 + #10);
WriteFileString(theFile, 'Total Logs: ' + IntToStr(TotalLogs) + #13 + #10);
WriteFileString(theFile, 'Total Exp: ' + FloatToStr(TotalExp) + #13 + #10);
CloseFile(theFile); // Again, don't forget this!
end;
Check out a guide on INIs. I can't link you to one at the moment because I'm in my phone, but a search for "WriteINI" in Tutorial Island should get you going in the right direction.
<3
Originally Posted by Eminem
INI:
http://villavu.com/forum/showthread.php?t=44955
Or you could read up on SQLite:
http://docs.villavu.com/simba/scriptref/sqlite.html
There are currently 1 users browsing this thread. (0 members and 1 guests)