File Format

Worldographer’s file format is a text xml file. It starts with the file encoding:

<?xml version='1.0' encoding='utf-16'?>

Followed by information about the overall map:

<map type="WORLD" version=".82" continentFactor="-1" kingdomFactor="-1" provinceFactor="-1" worldToContinentHOffset="0.0" continentToKingdomHOffset="0.0" kingdomToProvinceHOffset="0.0" worldToContinentVOffset="0.0" continentToKingdomVOffset="0.0" kingdomToProvinceVOffset="0.0" traceImageFileName="C:\Users\Username\Documents\test.png" traceOpacity="0.5" traceWidth="0.8" traceHeight="0.6" traceTopLeftX="100" traceTopLeftY="50" hexWidth="46.188" hexHeight="40.0" hexOrientation="COLUMNS" mapProjection="FLAT" triangleSize="12">
  • type=”WORLD”
  • version:  Worldographer version which saved this file.
  • continentFactor: -1 if there was never a continent level made from a world level or vice versa, otherwise this is the number of hexes across in the continent map for every hex in the world map.
  • kingdomFactor: -1 if there was never a kingdom level made from a continent level or vice versa, otherwise this is the number of hexes across in the kingdom map for every hex in the continent map.
  • provinceFactor: Province level is not implemented.  Memory constraints were too high.  It is in the file format just in case there is a new approach which allows for it.
  • worldToContinentHOffset: Not currently used, but it was in place to shift the continent hexes over based on the world map.
  • continentToKingdomHOffset: Not currently used, but it was in place to shift the kingdom hexes over based on the continent map.
  • kingdomToProvinceHOffset: Province level is not implemented.  Memory constraints were too high.  It is in the file format just in case there is a new approach which allows for it.
  • worldToContinentVOffset: Not currently used, but it was in place to shift the continent hexes down based on the world map.
  • continentToKingdomVOffset: Not currently used, but it was in place to shift the kingdom hexes down based on the continent map.
  • kingdomToProvinceVOffset: Province level is not implemented.  Memory constraints were too high.  It is in the file format just in case there is a new approach which allows for it.
  • traceImageFileName (v.82+): Full path and filename of an image that is used to trace the map, if the user set that up.
  • traceOpacity: If tracing an image, this is the opacity percentage (as a decimal so .5 = 50%) of the map being edited over the image.
  • traceWidth (v.82+): If tracing an image, the percentage width the image is scaled (as a decimal so .5 = 50%) based on the image’s size in pixels.
  • traceHeight (v.82+): If tracing an image, the percentage heightthe image is scaled (as a decimal so .5 = 50%) based on the image’s size in pixels.
  • traceTopLeftX (v.82+): Whole number of horizontal pixels to shift the underlying image.
  • traceTopLeftY= (v.82+): Whole number of vertical pixels to shift the underlying image.
  • hexWidth: Hexagon’s number of pixels wide. (Can be decimal.)
  • hexHeight=Hexagon’s number of pixels high. (Can be decimal.)
  • hexOrientation: “COLUMNS” or “ROWS”
  • mapProjection: “FLAT” or “ICOSAHEDRAL”
  • triangleSize: If projection is icosahedral, denotes how many hexes make up each edge of each triangle. Ignored if the map is a flat projection.

Next, each map level gets it terrain/tiles listed in order.

<tiles viewLevel="WORLD" tilesWide="100" tilesHigh="50">
<tilerow>
Water Ocean -3 0.85 true false 49 0 0 0 0 0 0
Flat Farmland 1000 0.85 false false 44 3 39 0 7 6 1
Hills Forest Jungle 2000 0.85 false false 34 10 19 0 37 3 19
...
</tilerow>
...
</tiles>

The file will have “Tiles” entities for the WORLD, CONTINENT, and KINGDOM map view levels.  The tiles entity notes which view level it matches and the number of tiles wide and high in that view level.  Each row will have its own tilerow entity which will have a number of tab delimited rows matching the tileshigh value.  Each row has the following values tab delimited: Terrain type, elevation, is it icy, is it GM only, and its resources (animals, brick, crops, gems, lumber, metals, and rock in that order).

Why was it done this way?  Why not have an entity for each tile/terrain?  Or why not just have each tile/terrain of the entire view level be its own tab-delimited text row in the tiles entity?  Memory issues in the parser when on the kingdom level where a map can easily be 6000×4000 hexes.  Either the string becomes too long and we run out of memory (in the latter case) or there are too many entities (in the former case).

Next we move to features:

<features>
<feature type="Settlement Isometric Medieval City A" rotate="0.0" scale="50.0" scaleHt="-1.0" tags="" color="null" ringcolor="null" isGMOnly="false" isPlaceFreely="true" isWorld="true" isContinent="true" isKingdom="true" isProvince="true" isFillHexBottom="false" isHideTerrainIcon="false"><location viewLevel="WORLD" x="4200.0" y="10950.0" /><label style="City" fontFace="Arial" color="0.0,0.0,0.0,1.0" outlineColor="0.0,0.0,0.0,1.0" rotate="0.0" isBold="false" isItalic="false" isWorld="true" isContinent="true" isKingdom="true" isProvince="true" isGMOnly="false" tags="town political">Oxminst</label>
</feature>
...
</features>

Note that X’s and Y’s for the locations of features, labels, and shapes are based on 300 pixels equals the width and height of a hex.  This feature has a label.

Followed by labels:

<labels>
<label style="Nation" fontFace="Arial" color="1.0,1.0,1.0,1.0" outlineColor="1.0,1.0,1.0,1.0" rotate="0.0" isBold="false" isItalic="false" isWorld="true" isContinent="true" isKingdom="false" isProvince="false" isGMOnly="false" tags="political nation"><location viewLevel="WORLD" x="4087.5" y="10725.0" scale="75.0" />Chitle</label>
...
</labels>

Then shapes:

<shape type="Polygon" isCurve="false" isGMOnly="false" isSnapVertices="false" tags="Chitle" creationType="BASIC" isDropShadow="false" isInnerShadow="false" isBoxBlur="false" isWorld="true" isContinent="true" isKingdom="true" isProvince="true" dsSpread="0.0" dsRadius="0.0" dsOffsetX="0.0" dsOffsetY="0.0" insChoke="0.0" insRadius="0.0" insOffsetX="0.0" insOffsetY="0.0" bbWidth="0.0" bbHeight="0.0" bbIterations="0" mapLayer="ABOVE_TERRAIN" fillTexture="" strokeTexture="" strokeType="0" highestViewLevel="WORLD" currentShapeViewLevel="WORLD" lineCap="SQUARE" lineJoin="MITER" strokeColor="1.0,1.0,1.0,1.0" strokeWidth="0.05" dsColor="null" insColor="null">
 <point x="4350.0" y="8850.0"/>
 <point x="4275.0" y="9000.0"/>
 <point x="4575.0" y="9000.0"/>
 <point x="4500.0" y="8850.0"/>
</shape>
</shapes>

Then notes:

(no example yet)

Followed by world information:

<informations>
<information uuid="6260100b-7cea-4b45-bf5c-7f0d21be3e4f" type="Information" title="Intro"><![CDATA[
]]>
</information>
<information uuid="ac542cfb-b66c-4060-b791-e80364586754" type="Information" title="Nations"><![CDATA[


]]>
<information rulers="Mariril, Pamilyn, Somerler, Clete, Wentlin, Snowmer" government="Oligarchy (military)" cultures="c0bc98de-dc94-45df-9070-baa6bf66a509" uuid="dac0af2e-9c51-4e40-a462-1f9ad2885ca3" type="Nation" title="Chitle"><![CDATA[<h2>Chitle</h2>
<ul>
<li>Government: Oligarchy (military)</li><li>Cultures: Roley</li>
<li>Rulers: Mariril, Pamilyn, Somerler, Clete, Wentlin, and Snowmer</li>
</ul>]]>
</information>
...
</information>


<information uuid="fe02e1c3-bd4a-4d63-aeb0-58802b38fad5" type="Information" title="Religions"><![CDATA[


]]>
<information religionType="Monotheistic" culture="c0bc98de-dc94-45df-9070-baa6bf66a509" holySymbol="Crown" domains="Nobility,Chaos,War" uuid="94d7dd5d-5bbf-4823-b0a3-eea35dd4452e" type="Religion" title="Braenia"><![CDATA[<h2>Braenia (Monotheistic)</h2>
<ul>
<li>Domains: Nobility, Chaos, and War</li>
<li>Holy Symbol: Crown</li>
<li>From the Roley culture.</li>
</ul>]]>
</information>
</information>
<information uuid="906a5423-5f81-43f3-a827-7dda73e01698" type="Information" title="Timelines"><![CDATA[
]]>
</information>
</informations>

Next comes a configuration section, so it gets a tag to start:

<configuration>

Then terrain configuration information (terrain info is only in the file if it is different than the default values & the terrain is actually used on the map) begins:

<terrain-config>
<terraintype type="ACExp Hills-Mixed-Forest" elevation="2000" similarTerrain="null" iconSize="0.85" isDefault="false" color="0.1764705926179886,0.250980406999588,0.09019608050584793,1.0" >rO0ABX
...
</terraintype>
...
 </terrain-config>

Followed by feature configuration information (feature info is only in the file if it is different than the default values & the feature is actually used on the map):

<feature-config>
<featuretype type="ACExp Cosmic AC-OuterSpace-Asteroids-A" iconSize="0.0" isDefault="false">rO0ABX
...
</featuretype>
...
</feature-config>

Then texture configuration info (if it is different than the default and used on the map):

<texture-config>
<texturetype type="xyzOrc-Monster-Lair-A" isDefault="false">rO0AB
...
</texturetype>
...
 </texture-config>

And Label configuration into (included even if not different than the defaults):

<text-config>
<labelstyle name="Nation" fontFace="Times" scale="80.0" isBold="false" isItalic="false" color="0.545098066329956,0.0,0.0,1.0" outlineColor="0.545098066329956,0.0,0.0,1.0" />
...
 </text-config>

Close the configuration section:

</configuration>

Close the map tag:

</map>