Search FAQ

MUSHclient scripting

Description of MUSHclient world function: world.Trace


Name Trace
Type Property
Summary Trace mode property
Prototype boolean Trace;
Description

Set to 1 to turn trace mode on, 0 to turn it off.

When trace mode is on debug messages appear in the output window. These occur when:

1. A trigger matches
2. A timer fires
3. An alias matches
4. A script executes
5. A script calls TraceOut.

VBscript example
world.trace = 1   ' turn trace on
world.trace = 0   ' turn trace off
world.note world.trace  ' display whether trace is on
Jscript example
world.trace = 1;   // turn trace on
world.trace = 0;   // turn trace off
world.Note(world.Trace);  // display whether trace is on
PerlScript example
$world->{trace} = 1;   # trace mode on
$world->{trace} = 0;   # trace mode off
$world->note($world->{trace});  # display whether trace is on
Python example
world.trace = 1   # turn trace on
world.trace = 0   # turn trace off
world.Note(world.Trace)  # display whether trace is on
Lua example
SetTrace (true)   -- turn trace on
SetTrace (false)   -- turn trace off
Note(GetTrace ())  -- display whether trace is on
Lua notes
Lua implements this as two functions:

GetTrace - gets whether tracing occurs
SetTrace - sets whether tracing occurs

The argument is optional, and defaults to true.
Returns This is a property. You can use it to find whether trace mode is on.

See also ...

Function Description
TraceOut Outputs the supplied message to the world Trace

Search for script function

Enter a word or phrase in the box below to narrow the list down to those that match.

The function name, prototype, summary, and description are searched.

Search for:   

Leave blank to show all functions.


Return codes

Many functions return a "code" which indicates the success or otherwise of the function.

You can view a list of the return codes


Function prototypes

The "prototype" part of each function description lists exactly how the function is called (what arguments, if any, to pass to it).

You can view a list of the data types used in function prototypes


View all functions

[Back]

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.