Gather all enchantment info into a single place

This also resolves several TODO notes about duplicate code and makes cPresetItem::ability an eEnchant
This commit is contained in:
2024-08-28 23:41:36 -04:00
committed by Celtic Minstrel
parent 71a9d11cd0
commit 6965b822dc
22 changed files with 216 additions and 83 deletions

View File

@@ -17,6 +17,17 @@
<xs:enumeration value="hostile-b"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="enchantment">
<xs:restriction base="xs:token">
<xs:enumeration value="+1"/>
<xs:enumeration value="+2"/>
<xs:enumeration value="+3"/>
<xs:enumeration value="+5"/>
<xs:enumeration value="shoot-flame"/>
<xs:enumeration value="flaming"/>
<xs:enumeration value="blessed"/>
</xs:restriction>
</xs:simpleType>
<xs:element name="town">
<xs:complexType>
@@ -129,7 +140,7 @@
<xs:complexType>
<xs:all>
<xs:element name="type" type="xs:integer"/>
<xs:element name="mod" type="xs:integer" minOccurs="0"/>
<xs:element name="mod" type="enchantment" minOccurs="0"/>
<xs:element name="charges" type="xs:integer" minOccurs="0"/>
<xs:element name="always" type="bool" minOccurs="0"/>
<xs:element name="property" type="bool" minOccurs="0"/>
@@ -211,4 +222,4 @@
<xs:field xpath='@id'/>
</xs:unique>
</xs:element>
</xs:schema>
</xs:schema>