<spanstyle="font-weight: bold;"></span>Nine attributes hold the information about a tile.
<spanstyle="font-weight: bold;"></span>Nine attributes hold the information about a tile.
This can be seen in the <ahref="landscape.html">Landscape</a> document. This page tries to give an overview of used and free bits of
This can be seen in the <ahref="landscape.html">Landscape</a> document. This page tries to give an overview of used and free bits of
the array so you can quickly see what is used and what is not.
the array so you can quickly see what is used and what is not.
<ul>
<li><spanstyle="font-weight: bold;"><spanclass="free">O</span></span> - bit is free</li>
<li><spanstyle="font-weight: bold;"><spanclass="used">X</span></span> - bit is used</li>
<li><spanstyle="font-weight: bold;"><spanclass="abuse"> </span></span> - bit of attribute is abused for different purposes, i.e. other bits define the actual meaning.</li>
<li><spanstyle="font-weight: bold;"><spanclass="option">~</span></span> - bit is accessed, but does not really have a meaning (e.g. owner of clear land is always OWNER_NONE)</li>
</ul>
<p>
<ul>
<ul>
<li><spanstyle="font-weight: bold;">type</span> - 8 bits in size, tile class (bits 4..7), bridge (bits 2..3) tropic zone (bits 0..1, only valid in tropic climate)</li>
<li><spanstyle="font-weight: bold;">type</span> - 8 bits in size, tile class (bits 4..7), bridge (bits 2..3) tropic zone (bits 0..1, only valid in tropic climate)</li>
<li><spanstyle="font-weight: bold;">height</span> - 8 bits in size, stores tile height</li>
<li><spanstyle="font-weight: bold;">height</span> - 8 bits in size, stores tile height</li>
@ -39,6 +37,16 @@ the array so you can quickly see what is used and what is not.
<li><spanstyle="font-weight: bold;">m7</span> - 8 bits in size, is used for general storage</li>
<li><spanstyle="font-weight: bold;">m7</span> - 8 bits in size, is used for general storage</li>
<li><spanstyle="font-weight: bold;">m8</span> - 16 bits in size, is used for general storage</li>
<li><spanstyle="font-weight: bold;">m8</span> - 16 bits in size, is used for general storage</li>
</ul>
</ul>
<p>
<ul>
<li><spanstyle="font-weight: bold;"><spanclass="free">O</span></span> - bit is free</li>
<li><spanstyle="font-weight: bold;"><spanclass="usable">X</span></span> - bit is used, but could be freed if needed</li>
<li><spanstyle="font-weight: bold;"><spanclass="used">X</span></span> - bit is used</li>
<li><spanstyle="font-weight: bold;"><spanclass="pool">X</span></span> - bit is used for an index on a pool</li>
<li><spanstyle="font-weight: bold;"><spanclass="patch">X</span></span> - bit is introduced by a patch</li>
<li><spanstyle="font-weight: bold;"><spanclass="abuse">X</span></span> - bit of attribute is abused for different purposes, i.e. other bits define the actual meaning</li>
<li><spanstyle="font-weight: bold;"><spanclass="rearrange">X</span></span> - bit is accessed, but a rearrangement of the map array could free some of these bits (probably not done for bit alignment)</li>
@ -71,134 +79,103 @@ the array so you can quickly see what is used and what is not.
<tr>
<tr>
<tdrowspan="2">0</td>
<tdrowspan="2">0</td>
<tdclass="caption">ground</td>
<tdclass="caption">ground</td>
<tdclass="bits">XXXX XXXX</td>
<tdclass="bits"rowspan=27><spanclass="used"title="Tile type">XXXX</span><spanclass="used"title="Presence and direction of bridge above">XX</span><spanclass="used"title="Tropic Zone: only meaningfull in tropic climate. It contains the definition of the available zones">XX</span></td>
<tdclass="bits"><spanclass="used"title="Type of hedge on NE border">XXX</span><spanclass="used"title="Snow presence">X</span><spanclass="free">OOOO</span></td>
<tdclass="bits"rowspan=2><spanclass="used"title="Type of hedge on SW border">XXX</span><spanclass="used"title="Type of hedge on SE border">XXX</span><spanclass="free">OO</span></td>
<tdclass="bits"rowspan=2><spanclass="used"title="Update counter">XXX</span><spanclass="used"title="Type: grass, rough land, rocks, fields, snow, desert">XXX</span><spanclass="used"title="Density">XX</span></td><tdclass="bits"rowspan=2><spanclass="free">OOO</span><spanclass="used"title="Type of hedge on NW border">X XX</span><spanclass="free">OO</span></td>
<tdclass="bits"rowspan=3><spanclass="used"title="Ship docking tile status (for half-tile with water)">X</span><spanclass="free">OO</span><spanclass="used"title="Owner">X XXXX</span></td>
<tdclass="bits"><spanclass="free">OOOO</span><spanclass="used"title="Ground type: fences, snow, desert (fences on depot are not valid)">XXXX</span></td>
<tdclass="bits"><spanclass="used"title="Tile type: simple road (00), level crossing (01), road depot (10)">OO</span><spanclass="used"title="Disallow vehicles to go a specific direction">XX</span><spanclass="used"title="Road pieces">XXXX</span></td>
<tdclass="bits"><spanclass="free">OOO</span><spanclass="used"title="Owner of rail track">X XXXX</span></td>
<tdclass="bits">-inherit-</td>
<tdclass="bits"><spanclass="used"title="Owner of tram">XXXX</span><spanclass="free">OOOO</span></td>
<tdclass="bits">-inherit-</td>
<tdclass="bits"><spanclass="used"title="Tile type: simple road (00), level crossing (01), road depot (10)">O1</span><spanclass="used"title="Lights are on">X</span><spanclass="used"title="PBS reservation">X</span><spanclass="free">OOO</span><spanclass="used"title="Direction of the rail and roads">X</span></td>
<tdclass="bits"><spanclass="free">OO</span><spanclass="used"title="Snow/desert present">X</span><spanclass="used"title="Owner of road">XXXXX</span></td>
<tdclass="bits"><spanclass="free">OO</span><spanclass="used"title="Snow/desert present">X</span><spanclass="usable"title="Owner of road depot">XXXXX</span></td>
<tdclass="bits"rowspan=2><spanclass="used"title="House random bits">XXXX XXXX</span></td>
<tdclass="bits">XXXX XXXX</td>
<tdclass="bits"rowspan=2><spanclass="pool"title="Town index on pool">XXXX XXXX XXXX XXXX</span></td>
<tdclass="bits">XXXX XXXX</td>
<tdclass="bits"><spanclass="used"title="House is complete/in construction (see m5)">1</span><spanclass="used"title="House type (m4 + m3[6])">X</span><spanclass="free">O</span><spanclass="usable"title="Activated triggers (bits 2..4 don't have a meaning)">XXX</span><spanclass="used"title="Activated triggers (bits 2..4 don't have a meaning)">XX</span></td>
<tdclass="bits">XXXX XXXX XXXX XXXX</td>
<tdclass="bits"rowspan=2><spanclass="used"title="House type (m4 + m3[6])">XXXX XXXX</span></td>
<tdclass="bits"><spanclass="used"title="Age in years, clamped at 255">XXXX XXXX</span></td>
<tdclass="bits">XXXX XXXX</td>
<tdclass="bits"rowspan=2><spanclass="abuse"title="Newhouses activated: periodic processing time remaining; if not, lift position for houses 04 and 05">XXXX XX</span><spanclass="free">OO</span></td>
<tdclass="bits"rowspan=2><spanclass="abuse"title="If newhouses active, m7 is the current animation frame">XXXX</span><spanclass="abuse"title="If newhouses active, m7 is the current animantion frame; if not, lift behaviour for houses 04 and 05">XXXX</span></td>
<tdclass="bits"><spanclass="used"title="House is complete/in construction (see m5)">O</span><spanclass="used"title="House type (m4 + m3[6])">X</span><spanclass="free">O</span><spanclass="usable"title="Activated triggers (bits 2..4 don't have a meaning)">XXX</span><spanclass="used"title="Activated triggers (bits 2..4 don't have a meaning)">XX</span></td>
<tdclass="bits"><spanclass="used"title="Number of trees on tile (+1)">XX</span><spanclass="free">OO O</span><spanclass="used"title="Tree growth">XXX</span></td>
<tdclass="bits"><spanclass="used"title="Owner of tram">XXXX</span><spanclass="free">OOOO</span></td>
<tdclass="bits">-inherit-</td>
<tdclass="bits"><spanclass="free">OO</span><spanclass="used"title="Roadtype for road stop">XX XXXX</span></td>
<tdclass="bits">-inherit-</td>
<tdclass="bits"><spanclass="usable"title="Graphics index">OOOO O</span><spanclass="used"title="Graphics index: 00 (exit towards NE), 01 (exit towards SE), 02 (exit towards SW), 03 (exit towards NW), 04 (drive through X), 05 (drive through Y)">XXX</span></td>
<tdclass="caption">industry under construction</td>
<tdclass="bits"><spanclass="used"title="Completed industry">O</span><spanclass="used"title="Water class">XX</span><spanclass="free">O</span><spanclass="used"title="If under construction, construction counter and stage of construction">XXXX</span></td>
</tr>
</tr>
<tr>
<tr>
<tdrowspan=2>9</td>
<tdrowspan=2>9</td>
<tdclass="caption">tunnel entrance</td>
<tdclass="caption">tunnel entrance</td>
<tdclass="bits">XXXX XXXX</td>
<tdclass="bits"rowspan=2><spanclass="used"title="Ship docking tile status (for aqueducts)">X</span><spanclass="free">OO</span><spanclass="used"title="Owner">XXXXX</span></td>
<tdclass="bits"rowspan=2><spanclass="rearrange"title="Owner of tram (road only; a rearrangement can free some of these bits)">XXXX</span><spanclass="free">OOOO</span></td>
<tdclass="bits"><spanclass="used"title="Bridge or tunnel bit">O</span><spanclass="free">OO</span><spanclass="rearrange"title="PBS reservation (rail; a rearrangement can free some of these bits)">X</span><spanclass="used"title="Transport type">XX</span><spanclass="used"title="Direction of the tunnel/bridge">XX</span></td>
<tdclass="bits"rowspan=2><spanclass="free">OO</span><spanclass="used"title="Snow/desert present">X</span><spanclass="rearrange"title="Owner of road (road only; a rearrangement can free some of these bits)">X XXXX</span></td>
<tdclass="bits"rowspan=2><spanclass="free">OOOO</span><spanclass="used"title="Tram type">XXXX XX</span><spanclass="rearrange"title="Railway type (rail only; a rearrangement can free some of these bits)">XX XXXX</span></td>
<tdclass="bits"><spanclass="used"title="Bridge or tunnel bit">1</span><spanclass="free">OO</span><spanclass="rearrange"title="PBS reservation (rail; a rearrangement can free some of these bits)">X</span><spanclass="used"title="Transport type">XX</span><spanclass="used"title="Direction of the tunnel/bridge">XX</span></td>