Template:Tree/doc

The Tree template is used to display the parent-child hierarchy of an Instance. This can be useful in tutorials for showing what a reader might see in the Explorer panel.

Usage
A tree is started with the Tree template. The first and only argument should consist of one or more Tree/node templates.

Tree/node is where the real magic happens. It has fouroptions: Note that if the third option is specified, the second option must also be specified.
 * 1) The first option is the ClassName of the Instance to be displayed.
 * 2) The second option specifies the Name to display for the Instance. If unspecified, the ClassName will be used.
 * 3) The third option indicates children of the Instance. If specified, it should consist of more Tree/node templates. This option has three types of behavior:
 * If specified with children, an "expanded node" will be displayed next to the Instance, indicating that it has children, and is displaying them.
 * If specified, but left blank, an "unexpanded node" will be displayed instead, indicating that the Instance has children, but is not displaying them.
 * If unspecified, then no node will be displayed.
 * 1) The fourth option is either empty or not specified. If empty, a + is displayed even for expxanded nodes, to indicate partial expansion

Examples
The following source would display a Player's character model:

Would produce:

Generation script
A script can be used quickly generate wiki markup for this template from an object hierarchy.

Use Execute Script to run the following script, which generates wiki code from the current selection: