I am coding on a simple game and writing the *.xsd file.
My Problem is that the element should have as a content a number between 1 and 6, and the attribute should have a number between 1 and 4.
here is my code, but it does not function cause of the types:
<xsd:element name="roll" type="numb_1_and_6">
<xsd:complexType>
<xsd:attribute name="player" use="required">
<xsd:simpleType>
<xsd:restriction base="xsd:integer">
<xsd:minInclusive value="1" />
<xsd:maxInclusive value="4" />
</xsd:restriction>
</xsd:simpleType>
</xsd:attribute>
</xsd:complexType>
</xsd:element>
<xsd:simpleType name="numb_1_and_6">
<xsd:restriction base="xsd:integer">
<xsd:minInclusive value="1" />
<xsd:maxInclusive value="6" />
</xsd:restriction>
</xsd:simpleType>
The Problem is the numb_1_and_6-Type and the complex Type... So how to fix that?
greetings and thx in advance