Map Format Specification
Map
The file extension for maps is xml. A map starts with the xml declaration and the map tag.
<?xml version="1.0" ?>
<map>
[...]
</map>
Authors
Optional tag that contains the map authors.
<authors>
<author email="john.k@example.com">John Kent</author>
<author>Bruce Obama</author>
</authors>
Position
Denotes a position in 3D. Attributes float x, float y, float z.
<position x="2.5" y="1" z="5"/>
Rotation
Attributes degree int x, int y, int z.
<rotation x="0" y="-90" z="0"/>
Spawn Position
<spawn>
<position x="2.5" y="1" z="5"/>
<rotation x="0" y="-90" z="0"/>
</spawn>
Materials
<materials>
<material id="1" name="concrete/wall00"/>
<material id="2" name="metal/tiles00x3"/>
</materials>
Models
<model mesh="foo.obj" material="<material_id>">
<position x="5.25" y="-3" z="5"/>
<rotation x="0" y="0" z="0"/>
<scale x="0.5" y="4.0" z="4.0"/>
</model>
Walls
Required attributes
position, scale
Optional attributes
rotation
<wall material="<material_id>" name="<wall_name>">
<position x="5.25" y="-3" z="5"/>
<rotation x="0" y="0" z="0"/>
<scale x="0.5" y="4.0" z="4.0"/>
</wall>
Light
Define a point light.
Required attributes
- Position - float x, float y, float z
- Color - float r, float g, float b
- Distance - float distance
- Energy - float energy
Optional attributes
- specular - int specular
<light distance="20" energy="5" specular="0"/>
<position x="5.25" y="-3" z="5"/>
<color r="0.9" g="0.9" b="0.9"/>
</light>