view dtds/race.xsd @ 21:1e18de815472

Re #32 - Migrate WarFoundry to schemas * Add "WarFoundry-Core" schema to define numerical types with -1 taking a special value * Add "WarFoundry-Cats" to store common category definition between race and system * Add full system schema * Add partial implementation of race schema Re #34 - Remove choices and base/increment * "WarFoundry-Cats" schema only includes min/max points and percentage
author IBBoard <dev@ibboard.co.uk>
date Sat, 07 Mar 2009 20:47:32 +0000
parents
children 28e99aa0053f
line wrap: on
line source

<?xml version="1.0"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:core="http://ibboard.co.uk/warfoundry/core" xmlns:cats="http://ibboard.co.uk/warfoundry/cats"
targetNamespace="http://ibboard.co.uk/warfoundry/race" xmlns="http://ibboard.co.uk/warfoundry/race" elementFormDefault="qualified">
<xs:element name="race">
  <xs:complexType>
    <xs:sequence>
      <xs:element name="units" type="unitstype"/>
      <xs:element name="categories" type="cats:categoriestype" />
      <xs:element name="equipment" type="equipmenttype" />
      <xs:element name="abilities" type="abilitiestype" />
    </xs:sequence>
    <xs:attribute name="id" type="xs:ID" />
    <xs:attribute name="subid" type="xs:string" default=""/>
    <xs:attribute name="name" type="xs:string" use="required"/>
    <xs:attribute name="system" type="xs:string" use="required"/>
  </xs:complexType>
</xs:element>
<xs:complexType name="unitstype">
  <xs:sequence>
    <xs:element name="unit" type="unittype" minOccurs="1" maxOccurs="unbounded"/>
  </xs:sequence>
</xs:complexType>
<xs:complexType name="unittype">
  <xs:sequence>
    <xs:element name="unitCats" type="unitcatstype"/>
    <xs:element name="stats" type="statstype" />
    <xs:element name="unitEquipment" type="unitequipmenttype" />
    <xs:element name="requirements" type="requirementstype" />
    <xs:element name="contains" type="containstype" />
    <xs:element name="requirements" type="requirementstype" />
  </xs:sequence>
  <xs:attribute name="id" type="xs:ID" />
  <xs:attribute name="typeName" type="xs:string" use="required"/>
  <xs:attribute name="cat" type="xs:string" use="required"/>
  <xs:attribute name="unitPoints" type="core:nonNegativeDecimal" default="0"/>
  <xs:attribute name="points" type="core:nonNegativeDecimal" use="required"/>
  <xs:attribute name="minNumber" type="core:nonNegativeInteger" default="0"/>
  <xs:attribute name="maxNumber" type="core:infiniteOrNonNegativeInteger" default="-1"/>
  <xs:attribute name="minSize" type="core:positiveInteger" default="5"/>
  <xs:attribute name="maxSize" type="core:infiniteOrNonNegativeInteger" default="-1"/>
  <xs:attribute name="baseSize" type="xsd:nonNegativeInteger" default="0"/>
</xs:complexType>
<xs:complexType name="statstype">
  <xs:sequence>
    <xs:element name="stat" type="stattype" minOccurs="1" maxOccurs="unbounded"/>
  </xs:sequence>
</xs:complexType>
<xs:complexType name="stattype">
  <xs:simpleContent>
    <xs:extension base="xs:string"/>
  </xs:simpleContent>
  <xs:attribute name="name" type="xs:string" use="required"/>
</xs:complexType>
</xs:schema>