Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • CARRIED (this one is implicit, if no <usage> is definied )

  • EMBEDDED - for all kinds of accessories (requires slot= and supports size= attributes)

  • IMPLANTED - for all bodyware (items costing essence)

Info

If no usage element is present, a CARRIED usage mode is assumed.

Items with variants

Variants are different versions of the same item. If an item has variants, it copies all attributes from the main item and allows you to override those attributes or even add new ones.

...

The application will ensure that decisions are made all present when an item is added to the character.

Dynamic table lookups

Sometimes values depending on a (rating) choice cannot be expressed in a formula.

...

In the example above, the essence can be expressed in a formula, but the other attributes cannot. For this case the attrdef element has an optional table attribute, which is used after the value attribute has been calculated.

Code Block
languagexml
<item id="cybereye" type="CYBERWARE" subtype="CYBER_EYEWARE">
  <choices>
    <choice uuid="fcc63c09-5af7-4f00-a2d9-d7c0972597d2" type="ITEM_ATTRIBUTE" ref="RATING" options="1,2,3,4,5"/>
  </choices>
  <usage mode="IMPLANTED"/>
  <attrdef id="ESSENCECOST"  value="$RATING*0.1" />
  <attrdef id="PRICE"        value="$RATING" table="1000,4000,6000,10000,16000"/>
  <attrdef id="AVAILABILITY" value="$RATING" table="2,2,3,3,3"/>
  <modifications>
    <valmod type="HOOK" ref="CYBEREYE_IMPLANT" value="$RATING" table="1,4,8,12,16"/>
    <embed  type="GEAR" ref="image_link" intoType="HOOK" intoRef="INTERNAL" included="true"/>
  </modifications>
</item>

The $RATING has a range from 1-5. It is used to look up in the table and use that result instead.

Info

The result of the formula in the value attribut must be a positive (1 or higher) integer and may not have a value higher than the elements in the comma-separated table.

Note that the table can be used in the attrdef element as well as in the valmod modification element.