TScript.DebugMode

From Soldat Community Wiki
Revision as of 16:13, 12 August 2013 by Mighty (talk | contribs) (new page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
property DebugMode: Boolean
 Access mode: R

Description

TRUE if debug mode is ON.
This can be changed in ScriptCore3_config_file
This feature is, as the name says, very useful when debugging or developing script.

Example

Config.ini :

[Config]
Name = Example
MainFile = example.pas
Sandboxed = 2
Debug = 1

example.pas :

procedure Debug(Msg: string);
begin
  if Script.DebugMode then
    WriteLn('['+Script.Name+'] '+Msg);
end;

begin
  Debug('Server has started');
end.