Mercurial > repos > snowblizz-super-API-ideas
comparison dtds/army.xsd @ 36:0a1c5fea6a08
Re #32 - Migrate to schemas
* Convert Army to schema
* Delete old DTDs
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Mon, 16 Mar 2009 20:15:02 +0000 |
parents | |
children | e53ed2d613a1 |
comparison
equal
deleted
inserted
replaced
35:9cac51553fd1 | 36:0a1c5fea6a08 |
---|---|
1 <?xml version="1.0"?> | |
2 <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ibboard.co.uk/warfoundry/army" xmlns="http://ibboard.co.uk/warfoundry/army" elementFormDefault="qualified"> | |
3 <xs:element name="army"> | |
4 <xs:complexType> | |
5 <xs:all> | |
6 <xs:element name="units" type="unitstype" minOccurs="1"/> | |
7 <xs:element name="customEquipment" type="customequipmenttype" minOccurs="1" /> | |
8 </xs:all> | |
9 <xs:attribute name="id" type="xs:ID" /> | |
10 <xs:attribute name="name" type="xs:string" use="required"/> | |
11 <xs:attribute name="system" type="xs:string" use="required"/> | |
12 <xs:attribute name="race" type="xs:string" use="required"/> | |
13 <xs:attribute name="maxPoints" type="xs:positiveInteger" use="required"/> | |
14 </xs:complexType> | |
15 </xs:element> | |
16 <xs:complexType name="unitstype"> | |
17 <xs:sequence> | |
18 <xs:element name="unit" type="unittype" minOccurs="0" maxOccurs="unbounded"/> | |
19 </xs:sequence> | |
20 </xs:complexType> | |
21 <xs:complexType name="unittype"> | |
22 <xs:all> | |
23 <xs:element name="equipment" type="equipmenttype" minOccurs="0" maxOccurs="1" /> | |
24 </xs:all> | |
25 <xs:attribute name="id" type="xs:ID" /> | |
26 <xs:attribute name="unitType" type="xs:string" use="required"/> | |
27 <xs:attribute name="unitName" type="xs:string" use="required"/> | |
28 <xs:attribute name="size" type="xs:positiveInteger" use="required"/> | |
29 <xs:attribute name="race" type="xs:string" default=""/> | |
30 </xs:complexType> | |
31 <xs:complexType name="equipmenttype"> | |
32 <xs:sequence> | |
33 <xs:element name="equipItem" type="equipitemtype" minOccurs="1" maxOccurs="unbounded"/> | |
34 </xs:sequence> | |
35 </xs:complexType> | |
36 <xs:complexType name="equipitemtype"> | |
37 <xs:attribute name="id" type="xs:string" /> <!-- ID reference to either a custom equipment item or a Race equipment item --> | |
38 <xs:attribute name="amount" type="xs:double" use="required"/><!-- Double used to allow for percentages to be stored --> | |
39 <xs:attribute name="isCustomEquipment" type="xs:boolean" default="false"/> | |
40 </xs:complexType> | |
41 <xs:complexType name="customequipmenttype"> | |
42 <xs:sequence> | |
43 <xs:element name="customEquip" type="customequiptype" minOccurs="0" maxOccurs="unbounded"/> | |
44 </xs:sequence> | |
45 </xs:complexType> | |
46 <xs:complexType name="customequiptype"> | |
47 <xs:sequence> | |
48 <xs:element name="customEquipPart" type="customequipparttype" minOccurs="1" maxOccurs="unbounded"/> | |
49 </xs:sequence> | |
50 <xs:attribute name="id" type="xs:ID" /> | |
51 </xs:complexType> | |
52 <xs:complexType name="customequipparttype"> | |
53 <xs:attribute name="partIDRef" type="xs:string" /> | |
54 </xs:complexType> | |
55 </xs:schema> |