Definition Type Element
Name expression-tabs
Abstract False
MinOccurs 0
MaxOccurs unbounded
Documentation Definition of tabs for use in a Dice Dialog.
XSD Schema Character Sheet Definition.xsd
XSD Schema Diagram
XSD Schema Code
<xs:element minOccurs="0" maxOccurs="unbounded" name="expression-tabs" >
  <xs:annotation>
    <xs:documentation>Definition of tabs for use in a Dice Dialog.</xs:documentation>
  </xs:annotation>

  <xs:complexType>
    <xs:sequence>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="expression-tab">
        <xs:annotation>
          <xs:documentation>An individual tab in the Dice Dialog.</xs:documentation>
        </xs:annotation>

        <xs:complexType>
          <xs:sequence>
            <xs:choice maxOccurs="unbounded">
              <xs:element minOccurs="0" maxOccurs="unbounded" name="source-id" type="xs:string">
                <xs:annotation>
                  <xs:documentation>The ID of a table or field that is the source of expressions for this tab.</xs:documentation>
                </xs:annotation>

              </xs:element>

              <xs:element minOccurs="0" name="name" type="xs:string">
                <xs:annotation>
                  <xs:documentation>The name of this tab, which is displayed in the Dice Dialog, unless an icon is defined.

If the &quot;use-name-in-tab&quot; flag is set, then this name will also be displayed in addition to an icon.
</xs:documentation>
                </xs:annotation>

              </xs:element>

              <xs:element minOccurs="0" name="icon" type="xs:string">
                <xs:annotation>
                  <xs:documentation>A icon to display in this tab.  This can either be one of the default icons bundled with the program, or a relative path to an image file, based off of where the program is installed.

If using a relative path, then Player will need to have this image file in the exact same location as the Master in order for the program to find and load it.
</xs:documentation>
                </xs:annotation>

              </xs:element>

              <xs:element minOccurs="0" name="tooltip" type="xs:string">
                <xs:annotation>
                  <xs:documentation>A tooltip to display when the user hovers his mouse pointer over the tab.</xs:documentation>
                </xs:annotation>

              </xs:element>

              <xs:element minOccurs="0" maxOccurs="unbounded" name="button">
                <xs:annotation>
                  <xs:documentation>A button placed at the top of this tab.

A button is, essentially, an expression that is evaluated when the button is pressed.

Note that the various tags and labels associated with a button are meant to contain not simple literal values, but also tokens or IDs of other fields.  In this fashion you can define expressions that reference data contained in other places on the character sheet.
</xs:documentation>
                </xs:annotation>

                <xs:complexType>
                  <xs:sequence>
                    <xs:choice maxOccurs="unbounded">
                      <xs:element minOccurs="0" name="button-label" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The label to render on the face of this button.

This value can contain tokens and field IDs, which will be evaluated and expanded when the label is rendered.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="button-sub-label" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>An additional label to render on the face of this button when it is placed in a Dice Panel.

This value can contain tokens and field IDs, which will be evaluated and expanded when the label is rendered.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="type" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The type of expression/button.  Only one of a perdefined list of types are supported.

These types are:

  button - an expression with no special handling
  toggle  - an expression that is added to some other expression
  init        - an initiative experssion
  attrib    - an attribute expression
  save     - a save expression
  attack   - an attack expression
  damage - a damage expression
  spell       - a spell expression
  skill         - a skill expression
  clc          - a &quot;caster level check&quot; expression
  custom   - a custom expression

Not all the expression types indicate that special handling is done, but by specifying the correct type, you indicate to the program that certain handling is expected and, should this handling be expanded in the future, you will be able to take advantage of it without further alteration.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="raw-label" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The &quot;raw&quot; or &quot;base&quot; identification of this expression.  When multiple Icons are selected and a roll performed, the program will evaluate whether all the Icons have matching expressions based on this label.

As such, it should not contain any information specify to a particular Icon.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" default="false" name="exclude-value" type="xs:boolean">
                        <xs:annotation>
                          <xs:documentation>Flag indicating that any value associated with this field/button should be excluded from the expression.

This is especially useful for items that do not actually have any particular value (like buttons) or fields that contain something that will not actually be used in the expression.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" default="false" name="ignore-targets" type="xs:boolean">
                        <xs:annotation>
                          <xs:documentation>Flag indicating that when this expression is evaluated, any targets that the issuing Icon has should be ignored.

This is useful for &quot;skill&quot; and similar expression types that are not evaluated &quot;against&quot; a target, but might be rolled while the Icon is targeting someone.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" default="false" name="low-to-succeed" type="xs:boolean">
                        <xs:annotation>
                          <xs:documentation>Flag indicating that the success or failure of this expression should be determined by a low result.

This is generally used in conjunction with a &quot;target-value&quot; in game systems that support this notion.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" default="true" name="high-to-succeed" type="xs:boolean">
                        <xs:annotation>
                          <xs:documentation>Flag indicating that the success or failure of this expression should be determined by a high result.

This is generally used in conjunction with a &quot;target-value&quot; in game systems that support this notion.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" default="false" name="discard-remainder" type="xs:boolean">
                        <xs:annotation>
                          <xs:documentation>Flag indicating that if the result of this expression does not evaluate to a whole number, the remainder should be discarded.

Game system vary their rules for how/when/if remainders are allowed and how those remainders are treated.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" default="false" name="remainder-round-down" type="xs:boolean">
                        <xs:annotation>
                          <xs:documentation>Flag indicating that if the result of this expression does not evaluate to a whole number, the remainder should be used to round the result down to the next lowest whole number.

Game system vary their rules for how/when/if remainders are allowed and how those remainders are treated.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" default="false" name="remainder-roiund-up" type="xs:boolean">
                        <xs:annotation>
                          <xs:documentation>Flag indicating that if the result of this expression does not evaluate to a whole number, the remainder should be used to round the result up to the next highest whole number.

Game system vary their rules for how/when/if remainders are allowed and how those remainders are treated.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="hit-sound" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The name of a sound file to be played when it is determined that this expression results in a &quot;hit.&quot;

This value is only relavent when the expression's type is &quot;attack.&quot;
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="miss-sound" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The name of a sound file to be played when it is determined that this expression results in a &quot;miss.&quot;

This value is only relavent when the expression's type is &quot;attack.&quot;
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="critical-hit-sound" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The name of a sound file to be played when it is determined that this expression results in a &quot;critical hit.&quot;

This value is only relavent when the expression's type is &quot;attack.&quot;
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="critical-miss-sound" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The name of a sound file to be played when it is determined that this expression results in a &quot;critical miss.&quot;

This value is only relavent when the expression's type is &quot;attack.&quot;
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="damage-sound" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The name of a sound file to be played when this expression is evaluated.

This value is only relavent when the expression's type is &quot;damage.&quot;
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="spell-sound" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The name of a sound file to be played when this expression is evaluated.

This value is only relavent when the expression's type is &quot;spell.&quot;
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="applied-effect" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The name of a pre-defined Icon Effect to apply to the targeted Icon when this expression is evaluated.

Pre-defined Icon Effects are set up by the Master and maintained by him.  In order to be applied, the value of this tag must match exactly the description of a pre-defined Icon Effect.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="hand" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>Reference to where &quot;hand&quot; information about the expression can be retrieved.

This information is used by the program when rendering various aspects of an expression to pass information on to the user.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" maxOccurs="1" name="armed" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The ID of a field that indicates whether this item is considered to be &quot;armed&quot; (ie, ready for use).

A state of &quot;armed&quot; does not really impact the behavior of the program, unless the Master has set the Preferences option that forces an expression to be &quot;armed&quot; before it will be evaluated.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="desc-label" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A descriptive labe for this expression.  This is only used for &quot;old style&quot; expression menus.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="target-value" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The &quot;target&quot; that the expression should be evaluated against.

For game systems that support this notion, this value contributes to the program determining whether the result of the expression evaluates to success or failure.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="pre-roll" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A piece of the expression to be inserted before the main portion of the expression is built.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="post-roll" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A piece of the expression to be inserted after the main portion of the expression is built.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="pre-expr" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A piece of the expression that is inserted immediately prior to the main expression.

Where &quot;pre-roll&quot; is intended to be generally used to issue descriptive chat text concerning the expression, this tag is used to alter eactly what the expression contains.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="post-expr" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A piece of the expression that is inserted immediately after the main expression.

Where &quot;post-roll&quot; is intended to be generally used to issue descriptive chat text concerning the expression, this tag is used to alter eactly what the expression contains.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="die-to-use" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The ID of a previously defined die to be used as the main payload of this expression.

For &quot;custom,&quot; &quot;spell&quot; and &quot;button&quot; expression types, it is assumed that no predefined die will be used, so this tag is generally ignored.  For other expression types, however, this makes up the bulk of the expression's payload.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="static-label" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A label that is used in the &quot;old style&quot; of Dice Dialogs and menus.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="critical-check" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A value to be used to determine a &quot;critical hit.&quot;

Generally this value should point to another field, where the user will enter data pertinent to this evaluation.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="critical-miss-check" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A value to be used to determine a &quot;critical miss.&quot;

Generally this value should point to another field, where the user will enter data pertinent to this evaluation.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="sound" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A sound file to play when this expression is evaluated.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="effect" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A visual effect to render when this expression is evaluated.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="exclude-above" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates in excess of, will be discarded.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="exclude-below" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates lower than, will be discarded.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="reroll-above" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates in excess of, will be re-rolled.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="reroll-above-save" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates in excess of, will be discarded, but the number of discardings is retained.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="reroll-below-save" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates lower than, will be discarded, but the number of discardings is retained.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="success-above" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A value which, if the expression evaluates in excess of, will indicate success.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="success-below" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A value which, if the expression evaluates lower than, will indicate success.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="no-damage" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The ID of a field that indicates to the program that this expression should never be considered to adjust hit points.

This is useful for expressions of the &quot;spell&quot; variety that may or may not adjust hit points.  By indicating to the program where it can look for a hint, it is better able to determine whether or not to adjust hit points.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="quantity" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The ID of a field where the program can look for quantity information.

The notion of &quot;quantity&quot; applies to an expression that, with a single evaluation, may disberse its results amongst various targets.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" maxOccurs="unbounded" name="check-availability">
                        <xs:annotation>
                          <xs:documentation>This clause instructs the program where to look to determine if the expression is available for evaluation.

If not present, then an expression is always considered to be available.
</xs:documentation>
                        </xs:annotation>

                        <xs:complexType>
                          <xs:sequence>
                            <xs:element minOccurs="0" name="memorized" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of the field where the program can find information about the number of this expression that is available.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="cost" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of the field where the program can find the &quot;cost&quot; of evaluating this expression.  This &quot;cost&quot; may be deducted from the value contained in the &quot;memorized&quot; field.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="cost-value" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A literal value for &quot;cost&quot; that is always used instead of a value contained in the character sheet data.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="compare-from" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of a field where the program can find comparison information.

For availablity that does not rely on a particular number of the expression being &quot;memorized,&quot; this value refers to a &quot;pool&quot; of resources from which multiple expressions can draw.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="compare-to" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of a field which contains data that must match data contained in the &quot;compare-from&quot; field.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="check-against" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of a field, in the same row as the &quot;compare-to&quot; field, whose value will be used to compare against.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" default="false" name="can-cast-up" type="xs:boolean">
                              <xs:annotation>
                                <xs:documentation>Flag that indicates whether availability fails if there are no matching data available.

Essentially, this covers the instance where the user can elect to use a slot where he has data available in exchange for a slot where he does not.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                          </xs:sequence>

                        </xs:complexType>

                      </xs:element>

                      <xs:element minOccurs="0" maxOccurs="unbounded" name="modify-on-roll">
                        <xs:annotation>
                          <xs:documentation>This clause instructs the program where to look to determine what fields should have their contents modified when this expression is evaluated.</xs:documentation>
                        </xs:annotation>

                        <xs:complexType>
                          <xs:sequence>
                            <xs:element minOccurs="0" name="memorized" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of the field where the program can find information about the number of this expression that is available.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="cost" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of the field where the program can find the &quot;cost&quot; of evaluating this expression.  This &quot;cost&quot; will be deducted from the value contained in the &quot;memorized&quot; field.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="cost-value" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A literal value for &quot;cost&quot; that is always used instead of a value contained in the character sheet data.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="compare-from" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of a field where the program can find comparison information.

For availablity that does not rely on a particular number of the expression being &quot;memorized,&quot; this value refers to a &quot;pool&quot; of resources from which multiple expressions can draw.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="compare-to" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of a field which contains data that must match data contained in the &quot;compare-from&quot; field.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="modify-field" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of the field to be modified.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" default="false" name="can-cast-up" type="xs:boolean">
                              <xs:annotation>
                                <xs:documentation>Flag that indicates whether modification fails if there are no matching data available.

Essentially, this covers the instance where the user can elect to use a slot where he has data available in exchange for a slot where he does not.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                          </xs:sequence>

                        </xs:complexType>

                      </xs:element>

                      <xs:element minOccurs="0" maxOccurs="1" name="actionable-def">
                        <xs:annotation>
                          <xs:documentation>This clause allows you to give the program a hint regarding which piece of multi-part expression should be used for hit point adjustment.

Primarily intended for expressions of the &quot;spell&quot; type, this clause is prone to failure.  The problem arises from the fact that a &quot;spell&quot; type can contain any number of expression pieces, any one of which (or none of which) may actually cause a hit point adjustment.

The &quot;no-damage&quot; tag is a refinement of this situation, but can not act alone.
</xs:documentation>
                        </xs:annotation>

                        <xs:complexType>
                          <xs:sequence>
                            <xs:element minOccurs="1" maxOccurs="1" name="total-clauses" type="xs:integer">
                              <xs:annotation>
                                <xs:documentation>The total number of pieces that this expression is expected to contain.

If the expression does not actually contain this many pieces, then no hit point adjustment will be done.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="1" maxOccurs="1" name="use-clause" type="xs:integer">
                              <xs:annotation>
                                <xs:documentation>The piece of the expression that should be used for hit point adjustment.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                          </xs:sequence>

                        </xs:complexType>

                      </xs:element>

                      <xs:element minOccurs="0" name="color" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The color to use when issuing the the chat message when this expression is evaluated.

This represents a &quot;default,&quot; which can be overridding by various other settings in the program.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="minimum" type="xs:integer">
                        <xs:annotation>
                          <xs:documentation>A minimum possible value for this expression.  If the expression is evaluated and the results is below this minimum, then the minimum value is used instead of the actual results.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="parse-script" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The name of a script to be executed when this expression is evaluated.

If this script returns a result, that result will be used instead of anything that the expression would otherwise generate.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="post-script" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>The name of a script to execute after this expression has been evaluated.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" maxOccurs="unbounded" name="parse-script-ex">
                        <xs:annotation>
                          <xs:documentation>A clause that defines a script to be executed during the &quot;parse&quot; phase of expression evaluation.

This differs from the &quot;parse-script&quot; tag in that this extended clause allows you to define and pass variables to the script before it is executed.

This allows you to have more generic scripts whose functionality is tailored by data contained in the character sheet.
</xs:documentation>
                        </xs:annotation>

                        <xs:complexType>
                          <xs:sequence>
                            <xs:element minOccurs="1" maxOccurs="1" name="script" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The script file name to execute.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="unbounded" name="args">
                              <xs:annotation>
                                <xs:documentation>List of arguments to define for the script.</xs:documentation>
                              </xs:annotation>

                              <xs:complexType>
                                <xs:sequence>
                                  <xs:element minOccurs="0" maxOccurs="unbounded" name="arg">
                                    <xs:annotation>
                                      <xs:documentation>An individual script variable.</xs:documentation>
                                    </xs:annotation>

                                    <xs:complexType>
                                      <xs:sequence>
                                        <xs:element minOccurs="1" name="name" type="xs:string">
                                          <xs:annotation>
                                            <xs:documentation>The name of the variable to be declared in the script's context.</xs:documentation>
                                          </xs:annotation>

                                        </xs:element>

                                        <xs:element minOccurs="1" name="value" type="xs:string">
                                          <xs:annotation>
                                            <xs:documentation>The value of the declared varible.</xs:documentation>
                                          </xs:annotation>

                                        </xs:element>

                                      </xs:sequence>

                                    </xs:complexType>

                                  </xs:element>

                                </xs:sequence>

                              </xs:complexType>

                            </xs:element>

                          </xs:sequence>

                        </xs:complexType>

                      </xs:element>

                      <xs:element minOccurs="0" maxOccurs="unbounded" name="post-script-ex">
                        <xs:annotation>
                          <xs:documentation>A clause that defines a script to be executed after the expression is evaluated.

This differs from the &quot;post-script&quot; tag in that this extended clause allows you to define and pass variables to the script before it is executed.

This allows you to have more generic scripts whose functionality is tailored by data contained in the character sheet.
</xs:documentation>
                        </xs:annotation>

                        <xs:complexType>
                          <xs:sequence>
                            <xs:element minOccurs="1" maxOccurs="1" name="script" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The script file name to execute.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="unbounded" name="args">
                              <xs:annotation>
                                <xs:documentation>List of arguments to define for the script.</xs:documentation>
                              </xs:annotation>

                              <xs:complexType>
                                <xs:sequence>
                                  <xs:element minOccurs="0" maxOccurs="unbounded" name="arg">
                                    <xs:annotation>
                                      <xs:documentation>An individual script variable.</xs:documentation>
                                    </xs:annotation>

                                    <xs:complexType>
                                      <xs:sequence>
                                        <xs:element minOccurs="1" name="name" type="xs:string">
                                          <xs:annotation>
                                            <xs:documentation>The name of the variable to be declared in the script's context.</xs:documentation>
                                          </xs:annotation>

                                        </xs:element>

                                        <xs:element minOccurs="1" name="value" type="xs:string">
                                          <xs:annotation>
                                            <xs:documentation>The value of the declared varible.</xs:documentation>
                                          </xs:annotation>

                                        </xs:element>

                                      </xs:sequence>

                                    </xs:complexType>

                                  </xs:element>

                                </xs:sequence>

                              </xs:complexType>

                            </xs:element>

                          </xs:sequence>

                        </xs:complexType>

                      </xs:element>

                      <xs:element minOccurs="0" name="rep-expr" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A replacement expression that will replace the base expression with its value.

This is a special-purpose tag whose intention is to allow you to replace the die portion of an expression with something else.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="tooltip" type="xs:string">
                        <xs:annotation>
                          <xs:documentation>A tooltip to apply to this button.</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" name="max-roll" type="xs:boolean">
                        <xs:annotation>
                          <xs:documentation>Flag indicating that any dice that occur in the expression should be maximized.  That is, if, for example, an expression contains &quot;{3d6+3},&quot; then the result will always be &quot;21&quot; since the &quot;3d6&quot; will always evaluate to &quot;18.&quot;

This flag is only honored on buttons of type &quot;toggle&quot; (since, otherwise, the expression would never be randomized) and, as a result, is intended to be used to modify another expression.
</xs:documentation>
                        </xs:annotation>

                      </xs:element>

                      <xs:element minOccurs="0" maxOccurs="unbounded" name="static-label-script-ex">
                        <xs:annotation>
                          <xs:documentation>A clause that defines a script to be executed to build an expression's label.

Unlike &quot;parse&quot; scripts, the script referenced by this tag must contain a &quot;getLabel()&quot; method that returns a String.  This string will be used, unaltered, in the program's interface to represent the expression.
</xs:documentation>
                        </xs:annotation>

                        <xs:complexType>
                          <xs:sequence>
                            <xs:element minOccurs="1" maxOccurs="1" name="script" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The script file name to execute.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="unbounded" name="args">
                              <xs:annotation>
                                <xs:documentation>List of arguments to define for the script.</xs:documentation>
                              </xs:annotation>

                              <xs:complexType>
                                <xs:sequence>
                                  <xs:element minOccurs="0" maxOccurs="unbounded" name="arg">
                                    <xs:annotation>
                                      <xs:documentation>An individual script variable.</xs:documentation>
                                    </xs:annotation>

                                    <xs:complexType>
                                      <xs:sequence>
                                        <xs:element minOccurs="1" name="name" type="xs:string">
                                          <xs:annotation>
                                            <xs:documentation>The name of the variable to be declared in the script's context.</xs:documentation>
                                          </xs:annotation>

                                        </xs:element>

                                        <xs:element minOccurs="1" name="value" type="xs:string">
                                          <xs:annotation>
                                            <xs:documentation>The value of the declared varible.</xs:documentation>
                                          </xs:annotation>

                                        </xs:element>

                                      </xs:sequence>

                                    </xs:complexType>

                                  </xs:element>

                                </xs:sequence>

                              </xs:complexType>

                            </xs:element>

                          </xs:sequence>

                        </xs:complexType>

                      </xs:element>

                    </xs:choice>

                  </xs:sequence>

                </xs:complexType>

              </xs:element>

              <xs:element minOccurs="0" maxOccurs="unbounded" name="combo">
                <xs:annotation>
                  <xs:documentation>A special interface element that is represented as a drop-down list.  This list contains button elements that are executed when the item in the list is selected by the user.

This is basically a way of getting a large number of buttons into a Dice Dialog without taking up a lot of space on the screen.
</xs:documentation>
                </xs:annotation>

                <xs:complexType>
                  <xs:sequence>
                    <xs:element minOccurs="0" name="label" type="xs:string">
                      <xs:annotation>
                        <xs:documentation>The label to be rendered next to this control.</xs:documentation>
                      </xs:annotation>

                    </xs:element>

                    <xs:element minOccurs="0" name="first-label" type="xs:string">
                      <xs:annotation>
                        <xs:documentation>The &quot;first label&quot; to be placed in the control.

This is a place-holder that is always displayed when the control is sitting idle.  Selecting it does not execute a roll and when any other item in the list is selected, this item is returned to the selected state afterwards.
</xs:documentation>
                      </xs:annotation>

                    </xs:element>

                    <xs:element minOccurs="0" maxOccurs="unbounded" name="button">
                      <xs:annotation>
                        <xs:documentation>A button placed at the top of this tab.

A button is, essentially, an expression that is evaluated when the button is pressed.

Note that the various tags and labels associated with a button are meant to contain not simple literal values, but also tokens or IDs of other fields.  In this fashion you can define expressions that reference data contained in other places on the character sheet.
</xs:documentation>
                      </xs:annotation>

                      <xs:complexType>
                        <xs:sequence>
                          <xs:choice maxOccurs="unbounded">
                            <xs:element minOccurs="0" name="button-label" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The label to render on the face of this button.

This value can contain tokens and field IDs, which will be evaluated and expanded when the label is rendered.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="type" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The type of expression/button.  Only one of a perdefined list of types are supported.

These types are:

  button - an expression with no special handling
  toggle  - an expression that is added to some other expression
  init        - an initiative experssion
  attrib    - an attribute expression
  save     - a save expression
  attack   - an attack expression
  damage - a damage expression
  spell       - a spell expression
  skill         - a skill expression
  clc          - a &quot;caster level check&quot; expression
  custom   - a custom expression

Not all the expression types indicate that special handling is done, but by specifying the correct type, you indicate to the program that certain handling is expected and, should this handling be expanded in the future, you will be able to take advantage of it without further alteration.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="raw-label" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The &quot;raw&quot; or &quot;base&quot; identification of this expression.  When multiple Icons are selected and a roll performed, the program will evaluate whether all the Icons have matching expressions based on this label.

As such, it should not contain any information specify to a particular Icon.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" default="false" name="exclude-value" type="xs:boolean">
                              <xs:annotation>
                                <xs:documentation>Flag indicating that any value associated with this field/button should be excluded from the expression.

This is especially useful for items that do not actually have any particular value (like buttons) or fields that contain something that will not actually be used in the expression.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" default="false" name="ignore-targets" type="xs:boolean">
                              <xs:annotation>
                                <xs:documentation>Flag indicating that when this expression is evaluated, any targets that the issuing Icon has should be ignored.

This is useful for &quot;skill&quot; and similar expression types that are not evaluated &quot;against&quot; a target, but might be rolled while the Icon is targeting someone.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" default="false" name="low-to-succeed" type="xs:boolean">
                              <xs:annotation>
                                <xs:documentation>Flag indicating that the success or failure of this expression should be determined by a low result.

This is generally used in conjunction with a &quot;target-value&quot; in game systems that support this notion.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" default="true" name="high-to-succeed" type="xs:boolean">
                              <xs:annotation>
                                <xs:documentation>Flag indicating that the success or failure of this expression should be determined by a high result.

This is generally used in conjunction with a &quot;target-value&quot; in game systems that support this notion.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" default="false" name="discard-remainder" type="xs:boolean">
                              <xs:annotation>
                                <xs:documentation>Flag indicating that if the result of this expression does not evaluate to a whole number, the remainder should be discarded.

Game system vary their rules for how/when/if remainders are allowed and how those remainders are treated.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" default="false" name="remainder-round-down" type="xs:boolean">
                              <xs:annotation>
                                <xs:documentation>Flag indicating that if the result of this expression does not evaluate to a whole number, the remainder should be used to round the result down to the next lowest whole number.

Game system vary their rules for how/when/if remainders are allowed and how those remainders are treated.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" default="false" name="remainder-roiund-up" type="xs:boolean">
                              <xs:annotation>
                                <xs:documentation>Flag indicating that if the result of this expression does not evaluate to a whole number, the remainder should be used to round the result up to the next highest whole number.

Game system vary their rules for how/when/if remainders are allowed and how those remainders are treated.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="hit-sound" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The name of a sound file to be played when it is determined that this expression results in a &quot;hit.&quot;

This value is only relavent when the expression's type is &quot;attack.&quot;
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="miss-sound" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The name of a sound file to be played when it is determined that this expression results in a &quot;miss.&quot;

This value is only relavent when the expression's type is &quot;attack.&quot;
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="critical-hit-sound" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The name of a sound file to be played when it is determined that this expression results in a &quot;critical hit.&quot;

This value is only relavent when the expression's type is &quot;attack.&quot;
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="critical-miss-sound" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The name of a sound file to be played when it is determined that this expression results in a &quot;critical miss.&quot;

This value is only relavent when the expression's type is &quot;attack.&quot;
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="damage-sound" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The name of a sound file to be played when this expression is evaluated.

This value is only relavent when the expression's type is &quot;damage.&quot;
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="spell-sound" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The name of a sound file to be played when this expression is evaluated.

This value is only relavent when the expression's type is &quot;spell.&quot;
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="applied-effect" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The name of a pre-defined Icon Effect to apply to the targeted Icon when this expression is evaluated.

Pre-defined Icon Effects are set up by the Master and maintained by him.  In order to be applied, the value of this tag must match exactly the description of a pre-defined Icon Effect.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="hand" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>Reference to where &quot;hand&quot; information about the expression can be retrieved.

This information is used by the program when rendering various aspects of an expression to pass information on to the user.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="1" name="armed" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of a field that indicates whether this item is considered to be &quot;armed&quot; (ie, ready for use).

A state of &quot;armed&quot; does not really impact the behavior of the program, unless the Master has set the Preferences option that forces an expression to be &quot;armed&quot; before it will be evaluated.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="desc-label" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A descriptive labe for this expression.  This is only used for &quot;old style&quot; expression menus.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="target-value" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The &quot;target&quot; that the expression should be evaluated against.

For game systems that support this notion, this value contributes to the program determining whether the result of the expression evaluates to success or failure.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="pre-roll" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A piece of the expression to be inserted before the main portion of the expression is built.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="post-roll" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A piece of the expression to be inserted after the main portion of the expression is built.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="pre-expr" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A piece of the expression that is inserted immediately prior to the main expression.

Where &quot;pre-roll&quot; is intended to be generally used to issue descriptive chat text concerning the expression, this tag is used to alter eactly what the expression contains.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="post-expr" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A piece of the expression that is inserted immediately after the main expression.

Where &quot;post-roll&quot; is intended to be generally used to issue descriptive chat text concerning the expression, this tag is used to alter eactly what the expression contains.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="die-to-use" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of a previously defined die to be used as the main payload of this expression.

For &quot;custom,&quot; &quot;spell&quot; and &quot;button&quot; expression types, it is assumed that no predefined die will be used, so this tag is generally ignored.  For other expression types, however, this makes up the bulk of the expression's payload.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="static-label" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A label that is used in the &quot;old style&quot; of Dice Dialogs and menus.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="critical-check" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A value to be used to determine a &quot;critical hit.&quot;

Generally this value should point to another field, where the user will enter data pertinent to this evaluation.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="critical-miss-check" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A value to be used to determine a &quot;critical miss.&quot;

Generally this value should point to another field, where the user will enter data pertinent to this evaluation.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="sound" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A sound file to play when this expression is evaluated.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="effect" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A visual effect to render when this expression is evaluated.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="exclude-above" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates in excess of, will be discarded.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="exclude-below" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates lower than, will be discarded.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="reroll-above" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates in excess of, will be re-rolled.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="reroll-above-save" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates in excess of, will be discarded, but the number of discardings is retained.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="reroll-below-save" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A value which, if the expression (or a piece of the expression) evaluates lower than, will be discarded, but the number of discardings is retained.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="success-above" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A value which, if the expression evaluates in excess of, will indicate success.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="success-below" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A value which, if the expression evaluates lower than, will indicate success.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="no-damage" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of a field that indicates to the program that this expression should never be considered to adjust hit points.

This is useful for expressions of the &quot;spell&quot; variety that may or may not adjust hit points.  By indicating to the program where it can look for a hint, it is better able to determine whether or not to adjust hit points.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="quantity" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The ID of a field where the program can look for quantity information.

The notion of &quot;quantity&quot; applies to an expression that, with a single evaluation, may disberse its results amongst various targets.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="unbounded" name="check-availability">
                              <xs:annotation>
                                <xs:documentation>This clause instructs the program where to look to determine if the expression is available for evaluation.

If not present, then an expression is always considered to be available.
</xs:documentation>
                              </xs:annotation>

                              <xs:complexType>
                                <xs:sequence>
                                  <xs:element minOccurs="0" name="memorized" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of the field where the program can find information about the number of this expression that is available.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="cost" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of the field where the program can find the &quot;cost&quot; of evaluating this expression.  This &quot;cost&quot; may be deducted from the value contained in the &quot;memorized&quot; field.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="cost-value" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>A literal value for &quot;cost&quot; that is always used instead of a value contained in the character sheet data.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="compare-from" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of a field where the program can find comparison information.

For availablity that does not rely on a particular number of the expression being &quot;memorized,&quot; this value refers to a &quot;pool&quot; of resources from which multiple expressions can draw.
</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="compare-to" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of a field which contains data that must match data contained in the &quot;compare-from&quot; field.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="check-against" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of a field, in the same row as the &quot;compare-to&quot; field, whose value will be used to compare against.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" default="false" name="can-cast-up" type="xs:boolean">
                                    <xs:annotation>
                                      <xs:documentation>Flag that indicates whether availability fails if there are no matching data available.

Essentially, this covers the instance where the user can elect to use a slot where he has data available in exchange for a slot where he does not.
</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                </xs:sequence>

                              </xs:complexType>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="unbounded" name="modify-on-roll">
                              <xs:annotation>
                                <xs:documentation>This clause instructs the program where to look to determine what fields should have their contents modified when this expression is evaluated.</xs:documentation>
                              </xs:annotation>

                              <xs:complexType>
                                <xs:sequence>
                                  <xs:element minOccurs="0" name="memorized" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of the field where the program can find information about the number of this expression that is available.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="cost" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of the field where the program can find the &quot;cost&quot; of evaluating this expression.  This &quot;cost&quot; will be deducted from the value contained in the &quot;memorized&quot; field.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="cost-value" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>A literal value for &quot;cost&quot; that is always used instead of a value contained in the character sheet data.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="compare-from" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of a field where the program can find comparison information.

For availablity that does not rely on a particular number of the expression being &quot;memorized,&quot; this value refers to a &quot;pool&quot; of resources from which multiple expressions can draw.
</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="compare-to" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of a field which contains data that must match data contained in the &quot;compare-from&quot; field.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" name="modify-field" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The ID of the field to be modified.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" default="false" name="can-cast-up" type="xs:boolean">
                                    <xs:annotation>
                                      <xs:documentation>Flag that indicates whether modification fails if there are no matching data available.

Essentially, this covers the instance where the user can elect to use a slot where he has data available in exchange for a slot where he does not.
</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                </xs:sequence>

                              </xs:complexType>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="1" name="actionable-def">
                              <xs:annotation>
                                <xs:documentation>This clause allows you to give the program a hint regarding which piece of multi-part expression should be used for hit point adjustment.

Primarily intended for expressions of the &quot;spell&quot; type, this clause is prone to failure.  The problem arises from the fact that a &quot;spell&quot; type can contain any number of expression pieces, any one of which (or none of which) may actually cause a hit point adjustment.

The &quot;no-damage&quot; tag is a refinement of this situation, but can not act alone.
</xs:documentation>
                              </xs:annotation>

                              <xs:complexType>
                                <xs:sequence>
                                  <xs:element minOccurs="1" maxOccurs="1" name="total-clauses" type="xs:integer">
                                    <xs:annotation>
                                      <xs:documentation>The total number of pieces that this expression is expected to contain.

If the expression does not actually contain this many pieces, then no hit point adjustment will be done.
</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="1" maxOccurs="1" name="use-clause" type="xs:integer">
                                    <xs:annotation>
                                      <xs:documentation>The piece of the expression that should be used for hit point adjustment.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                </xs:sequence>

                              </xs:complexType>

                            </xs:element>

                            <xs:element minOccurs="0" name="color" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The color to use when issuing the the chat message when this expression is evaluated.

This represents a &quot;default,&quot; which can be overridding by various other settings in the program.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="minimum" type="xs:integer">
                              <xs:annotation>
                                <xs:documentation>A minimum possible value for this expression.  If the expression is evaluated and the results is below this minimum, then the minimum value is used instead of the actual results.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="parse-script" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The name of a script to be executed when this expression is evaluated.

If this script returns a result, that result will be used instead of anything that the expression would otherwise generate.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" name="post-script" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>The name of a script to execute after this expression has been evaluated.</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="unbounded" name="parse-script-ex">
                              <xs:annotation>
                                <xs:documentation>A clause that defines a script to be executed during the &quot;parse&quot; phase of expression evaluation.

This differs from the &quot;parse-script&quot; tag in that this extended clause allows you to define and pass variables to the script before it is executed.

This allows you to have more generic scripts whose functionality is tailored by data contained in the character sheet.
</xs:documentation>
                              </xs:annotation>

                              <xs:complexType>
                                <xs:sequence>
                                  <xs:element minOccurs="1" maxOccurs="1" name="script" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The script file name to execute.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" maxOccurs="unbounded" name="args">
                                    <xs:annotation>
                                      <xs:documentation>List of arguments to define for the script.</xs:documentation>
                                    </xs:annotation>

                                    <xs:complexType>
                                      <xs:sequence>
                                        <xs:element minOccurs="0" maxOccurs="unbounded" name="arg">
                                          <xs:annotation>
                                            <xs:documentation>An individual script variable.</xs:documentation>
                                          </xs:annotation>

                                          <xs:complexType>
                                            <xs:sequence>
                                              <xs:element minOccurs="1" name="name" type="xs:string">
                                                <xs:annotation>
                                                  <xs:documentation>The name of the variable to be declared in the script's context.</xs:documentation>
                                                </xs:annotation>

                                              </xs:element>

                                              <xs:element minOccurs="1" name="value" type="xs:string">
                                                <xs:annotation>
                                                  <xs:documentation>The value of the declared varible.</xs:documentation>
                                                </xs:annotation>

                                              </xs:element>

                                            </xs:sequence>

                                          </xs:complexType>

                                        </xs:element>

                                      </xs:sequence>

                                    </xs:complexType>

                                  </xs:element>

                                </xs:sequence>

                              </xs:complexType>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="unbounded" name="post-script-ex">
                              <xs:annotation>
                                <xs:documentation>A clause that defines a script to be executed after the expression is evaluated.

This differs from the &quot;post-script&quot; tag in that this extended clause allows you to define and pass variables to the script before it is executed.

This allows you to have more generic scripts whose functionality is tailored by data contained in the character sheet.
</xs:documentation>
                              </xs:annotation>

                              <xs:complexType>
                                <xs:sequence>
                                  <xs:element minOccurs="1" maxOccurs="1" name="script" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The script file name to execute.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" maxOccurs="unbounded" name="args">
                                    <xs:annotation>
                                      <xs:documentation>List of arguments to define for the script.</xs:documentation>
                                    </xs:annotation>

                                    <xs:complexType>
                                      <xs:sequence>
                                        <xs:element minOccurs="0" maxOccurs="unbounded" name="arg">
                                          <xs:annotation>
                                            <xs:documentation>An individual script variable.</xs:documentation>
                                          </xs:annotation>

                                          <xs:complexType>
                                            <xs:sequence>
                                              <xs:element minOccurs="1" name="name" type="xs:string">
                                                <xs:annotation>
                                                  <xs:documentation>The name of the variable to be declared in the script's context.</xs:documentation>
                                                </xs:annotation>

                                              </xs:element>

                                              <xs:element minOccurs="1" name="value" type="xs:string">
                                                <xs:annotation>
                                                  <xs:documentation>The value of the declared varible.</xs:documentation>
                                                </xs:annotation>

                                              </xs:element>

                                            </xs:sequence>

                                          </xs:complexType>

                                        </xs:element>

                                      </xs:sequence>

                                    </xs:complexType>

                                  </xs:element>

                                </xs:sequence>

                              </xs:complexType>

                            </xs:element>

                            <xs:element minOccurs="0" name="rep-expr" type="xs:string">
                              <xs:annotation>
                                <xs:documentation>A replacement expression that will replace the base expression with its value.

This is a special-purpose tag whose intention is to allow you to replace the die portion of an expression with something else.
</xs:documentation>
                              </xs:annotation>

                            </xs:element>

                            <xs:element minOccurs="0" maxOccurs="unbounded" name="static-label-script-ex">
                              <xs:annotation>
                                <xs:documentation>A clause that defines a script to be executed to build an expression's label.

Unlike &quot;parse&quot; scripts, the script referenced by this tag must contain a &quot;getLabel()&quot; method that returns a String.  This string will be used, unaltered, in the program's interface to represent the expression.
</xs:documentation>
                              </xs:annotation>

                              <xs:complexType>
                                <xs:sequence>
                                  <xs:element minOccurs="1" maxOccurs="1" name="script" type="xs:string">
                                    <xs:annotation>
                                      <xs:documentation>The script file name to execute.</xs:documentation>
                                    </xs:annotation>

                                  </xs:element>

                                  <xs:element minOccurs="0" maxOccurs="unbounded" name="args">
                                    <xs:annotation>
                                      <xs:documentation>List of arguments to define for the script.</xs:documentation>
                                    </xs:annotation>

                                    <xs:complexType>
                                      <xs:sequence>
                                        <xs:element minOccurs="0" maxOccurs="unbounded" name="arg">
                                          <xs:annotation>
                                            <xs:documentation>An individual script variable.</xs:documentation>
                                          </xs:annotation>

                                          <xs:complexType>
                                            <xs:sequence>
                                              <xs:element minOccurs="1" name="name" type="xs:string">
                                                <xs:annotation>
                                                  <xs:documentation>The name of the variable to be declared in the script's context.</xs:documentation>
                                                </xs:annotation>

                                              </xs:element>

                                              <xs:element minOccurs="1" name="value" type="xs:string">
                                                <xs:annotation>
                                                  <xs:documentation>The value of the declared varible.</xs:documentation>
                                                </xs:annotation>

                                              </xs:element>

                                            </xs:sequence>

                                          </xs:complexType>

                                        </xs:element>

                                      </xs:sequence>

                                    </xs:complexType>

                                  </xs:element>

                                </xs:sequence>

                              </xs:complexType>

                            </xs:element>

                          </xs:choice>

                        </xs:sequence>

                      </xs:complexType>

                    </xs:element>

                  </xs:sequence>

                </xs:complexType>

              </xs:element>

              <xs:element minOccurs="0" maxOccurs="1" name="filter" type="xs:boolean">
                <xs:annotation>
                  <xs:documentation>A special interface element that adds a filter/search field to the tab of the Dice Panel.

When the user types text info this field, any rolls that do not match the entered text will be hidden.
</xs:documentation>
                </xs:annotation>

              </xs:element>

              <xs:element minOccurs="0" maxOccurs="unbounded" name="check-hit">
                <xs:annotation>
                  <xs:documentation>This clause defines where the program should look to determine hits or misses when an expression of type &quot;attack&quot; is evaluated.</xs:documentation>
                </xs:annotation>

                <xs:complexType>
                  <xs:sequence>
                    <xs:element minOccurs="0" maxOccurs="unbounded" name="ac-type" type="xs:string">
                      <xs:annotation>
                        <xs:documentation>The ID of the field whose value will be checked to determine whether the roll hits or misses.</xs:documentation>
                      </xs:annotation>

                    </xs:element>

                    <xs:element minOccurs="0" maxOccurs="unbounded" name="reduced-by">
                      <xs:annotation>
                        <xs:documentation>This clause allows you to tell the program where to look for information that might reduce the overall roll before determining a hit or miss.</xs:documentation>
                      </xs:annotation>

                      <xs:complexType>
                        <xs:sequence>
                          <xs:element minOccurs="1" name="field" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field that contains information about reducing the &quot;to hit&quot; roll.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" default="false" name="reduce-on-use" type="xs:boolean">
                            <xs:annotation>
                              <xs:documentation>Flag indicating that the value retrieved from the &quot;field&quot; field should, itself, be reduced by the amount of reduction applied.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                        </xs:sequence>

                      </xs:complexType>

                    </xs:element>

                  </xs:sequence>

                </xs:complexType>

              </xs:element>

              <xs:element minOccurs="0" maxOccurs="unbounded" name="apply-damage">
                <xs:annotation>
                  <xs:documentation>This clause tells the program where to look when an expression of type &quot;damage&quot; is evaluated.</xs:documentation>
                </xs:annotation>

                <xs:complexType>
                  <xs:sequence>
                    <xs:element minOccurs="0" name="hp-type" type="xs:string">
                      <xs:annotation>
                        <xs:documentation>The ID of the field whose value will be adjusted when an expression of type &quot;damage&quot; is evaluated.</xs:documentation>
                      </xs:annotation>

                    </xs:element>

                    <xs:element minOccurs="0" maxOccurs="unbounded" name="reduced-by">
                      <xs:annotation>
                        <xs:documentation>This clause allows you to tell the program where to look for information that might reduce the overall amount of adjustment applied to the &quot;hp-type&quot; field.</xs:documentation>
                      </xs:annotation>

                      <xs:complexType>
                        <xs:sequence>
                          <xs:element minOccurs="0" name="field" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field that contains information about reducing the amount of damage potentially applied.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" default="false" name="reduce-on-use" type="xs:boolean">
                            <xs:annotation>
                              <xs:documentation>Flag indicating that the value retrieved from the &quot;field&quot; field should, itself, be reduced by the amount of reduction applied.

For example, let's imagine that an Icon has a magical item that absorbs up to one hundred points of damage before turning to ash.  Every time this item is used, the &quot;reduce-on-use&quot; flag indicates to the program that it should subtract the amount of reduced damage from the value contained in the &quot;field&quot; field.
</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                        </xs:sequence>

                      </xs:complexType>

                    </xs:element>

                  </xs:sequence>

                </xs:complexType>

              </xs:element>

              <xs:element minOccurs="0" name="spell-setup">
                <xs:annotation>
                  <xs:documentation>This is a special interface element that places a button on the tab that accesses &quot;spell&quot; setup.</xs:documentation>
                </xs:annotation>

                <xs:complexType>
                  <xs:sequence>
                    <xs:element minOccurs="0" name="label" type="xs:string">
                      <xs:annotation>
                        <xs:documentation>The label to be placed in the button that is rendered on the tab.</xs:documentation>
                      </xs:annotation>

                    </xs:element>

                    <xs:element minOccurs="0" name="spell-level-source">
                      <xs:annotation>
                        <xs:documentation>This clause defines for the program where to look for spell level information.

In order to operate correctly, &quot;spell-setup&quot; must have a variety of information, including where to find spell level names, where the maximum number of spells of that level can be found and what the current number of spells of that level are found.
</xs:documentation>
                      </xs:annotation>

                      <xs:complexType>
                        <xs:sequence>
                          <xs:element minOccurs="0" name="table-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the table that contains spell level information.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" name="name-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field within the &quot;table-id&quot; table where the name of the spell level is located.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" name="max-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field within the &quot;table-id&quot; table where the maximum number of spells of this level is stored.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" name="cur-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field within the &quot;table-id&quot; table where the current number of spells of this level is stored.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                        </xs:sequence>

                      </xs:complexType>

                    </xs:element>

                    <xs:element minOccurs="0" name="spell-source">
                      <xs:annotation>
                        <xs:documentation>The ID of the table that contains the actual spell information.</xs:documentation>
                      </xs:annotation>

                      <xs:complexType>
                        <xs:sequence>
                          <xs:element minOccurs="0" name="table-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the table where spells are located.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" name="name-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field within the &quot;table-id&quot; table where the name of the spell is located.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" name="desc-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field within the &quot;table-id&quot; table where the description/expression of the spell is located.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" name="level-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field within the &quot;table-id&quot; table where the level of the spell is located.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" name="cost-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field within the &quot;table-id&quot; table where the cost (how many spell slots the spell requires) of the spell is located.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                          <xs:element minOccurs="0" name="mem-id" type="xs:string">
                            <xs:annotation>
                              <xs:documentation>The ID of the field within the &quot;table-id&quot; table where the number currently &quot;memorized&quot; of this spell is located.</xs:documentation>
                            </xs:annotation>

                          </xs:element>

                        </xs:sequence>

                      </xs:complexType>

                    </xs:element>

                    <xs:element minOccurs="0" default="false" name="dm-only" type="xs:boolean">
                      <xs:annotation>
                        <xs:documentation>Flag indicating that this button should only be rendered if the program is running in Master mode.</xs:documentation>
                      </xs:annotation>

                    </xs:element>

                    <xs:element minOccurs="0" default="false" name="hidden" type="xs:boolean">
                      <xs:annotation>
                        <xs:documentation>Flag indicating that this button should never be rendered.</xs:documentation>
                      </xs:annotation>

                    </xs:element>

                  </xs:sequence>

                </xs:complexType>

              </xs:element>

              <xs:element minOccurs="0" name="use-name-in-tab" type="xs:boolean">
                <xs:annotation>
                  <xs:documentation>Flag indicating whether the tab's &quot;name&quot; should be placed in the tab along with an icon.</xs:documentation>
                </xs:annotation>

              </xs:element>

            </xs:choice>

          </xs:sequence>

        </xs:complexType>

      </xs:element>

    </xs:sequence>

  </xs:complexType>

</xs:element>
Child Elements
Name Type Min Occurs Max Occurs
Derivation Tree
[No Sub Types]
expression-tabs
    [No Super Types]
Generated using Liquid XML Studio by Liquid Technologies Ltd