Nasal library/debug: Difference between revisions
Jump to navigation
Jump to search
Red Leader (talk | contribs) (→attributes(): Start) |
Red Leader (talk | contribs) No edit summary |
||
Line 21: | Line 21: | ||
! Data !! Meaning | ! Data !! Meaning | ||
|- | |- | ||
| type || Type of node as returned by {{func link| | | type || Type of node as returned by {{func link|getType()|props|Node}}. | ||
|} | |} | ||
Revision as of 18:56, 16 November 2016
Work in progress This article or section will be worked on in the upcoming hours or days. See history for the latest developments. |
The FlightGear forum has a subforum related to: Nasal Scripting |
Nasal scripting |
---|
Nasal internals |
---|
Memory Management (GC) |
This page contains documentation for the debug
namespace in Nasal. This namespace provides various useful APIs for debugging Nasal code. The debug
namespace is sourced from fgdata/Nasal/debug.nas.
Functions
attributes()
debug.attributes(p[, verbose[, color]]);
Returns a string showing the attributes of the node, in the form (type[, attr[, Lnum[, #refs]])
. See the table below for explanation.
- p
- Mandatory
props.Node
object. - verbose
- Optional bool specifying whether to show the number of times the node is referenced. Defaults to 1 (true).
- color
- Optional bool specifying whether to output the string with an ANSI color code . Defaults to
nil
.
Data | Meaning |
---|---|
type | Type of node as returned by props.Node.getType() .
|