Files @ r6634:969e8729aa7a
Branch filter:

Location: cpp/openttd-patchpack/source/docs/landscape_grid.html - annotation

glx
(svn r9865) -Fix (r9862): NOT_REACHED() and error() declarations are needed for strgen
r1484:58a94337283a
r1484:58a94337283a
r1484:58a94337283a
r1484:58a94337283a
r1487:755a14bc5e12
r1487:755a14bc5e12
r1487:755a14bc5e12
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r1487:755a14bc5e12
r1484:58a94337283a
r1484:58a94337283a
r1484:58a94337283a
r5596:84985796bbd9
r1487:755a14bc5e12
r1487:755a14bc5e12
r1484:58a94337283a
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r1484:58a94337283a
r1487:755a14bc5e12
r1487:755a14bc5e12
r2149:653fa1740f53
r2487:d3b52b578f6a
r2149:653fa1740f53
r2850:3b72482e7962
r2850:3b72482e7962
r2149:653fa1740f53
r5596:84985796bbd9
r6332:7393965b5322
r1487:755a14bc5e12
r1487:755a14bc5e12
r2853:5e0d9d8a2fa0
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r5596:84985796bbd9
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r5596:84985796bbd9
r6332:7393965b5322
r2018:5a1761d16521
r2018:5a1761d16521
r2853:5e0d9d8a2fa0
r2852:1ce7cf94377c
r5596:84985796bbd9
r2852:1ce7cf94377c
r2852:1ce7cf94377c
r2852:1ce7cf94377c
r2852:1ce7cf94377c
r2852:1ce7cf94377c
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r4593:43e7f6639554
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r5596:84985796bbd9
r2851:45eec56fdf44
r4593:43e7f6639554
r2852:1ce7cf94377c
r2851:45eec56fdf44
r5596:84985796bbd9
r6332:7393965b5322
r2851:45eec56fdf44
r2851:45eec56fdf44
r4593:43e7f6639554
r4593:43e7f6639554
r5596:84985796bbd9
r4593:43e7f6639554
r4593:43e7f6639554
r4593:43e7f6639554
r4593:43e7f6639554
r5596:84985796bbd9
r6332:7393965b5322
r4593:43e7f6639554
r4593:43e7f6639554
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r5596:84985796bbd9
r2852:1ce7cf94377c
r2851:45eec56fdf44
r2916:04b29c805eb5
r2851:45eec56fdf44
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r5596:84985796bbd9
r2851:45eec56fdf44
r2916:04b29c805eb5
r2853:5e0d9d8a2fa0
r2852:1ce7cf94377c
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r5596:84985796bbd9
r2853:5e0d9d8a2fa0
r4052:69c029a15bfe
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r5596:84985796bbd9
r6332:7393965b5322
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r5596:84985796bbd9
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r2853:5e0d9d8a2fa0
r5596:84985796bbd9
r2851:45eec56fdf44
r2851:45eec56fdf44
r2916:04b29c805eb5
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r5596:84985796bbd9
r2851:45eec56fdf44
r6172:7d1cba4c8187
r2851:45eec56fdf44
r2851:45eec56fdf44
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r6332:7393965b5322
r5596:84985796bbd9
r6332:7393965b5322
r2851:45eec56fdf44
r6332:7393965b5322
r2851:45eec56fdf44
r6332:7393965b5322
r6332:7393965b5322
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r5596:84985796bbd9
r2891:0026fd0ade9b
r2851:45eec56fdf44
r2852:1ce7cf94377c
r2852:1ce7cf94377c
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r5596:84985796bbd9
r2851:45eec56fdf44
r3742:a30bdea03972
r2851:45eec56fdf44
r2851:45eec56fdf44
r6068:768775df9390
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r5596:84985796bbd9
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r5596:84985796bbd9
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r5436:19a01d6e6b71
r2853:5e0d9d8a2fa0
r5596:84985796bbd9
r6332:7393965b5322
r6332:7393965b5322
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r6332:7393965b5322
r6332:7393965b5322
r6332:7393965b5322
r5596:84985796bbd9
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r5596:84985796bbd9
r2853:5e0d9d8a2fa0
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r5385:1c8ef6521bf2
r5596:84985796bbd9
r5596:84985796bbd9
r2851:45eec56fdf44
r2851:45eec56fdf44
r2852:1ce7cf94377c
r2916:04b29c805eb5
r3999:11007d71fa74
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r3195:0767da31c260
r3195:0767da31c260
r5596:84985796bbd9
r6332:7393965b5322
r6332:7393965b5322
r3195:0767da31c260
r3195:0767da31c260
r5385:1c8ef6521bf2
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r2853:5e0d9d8a2fa0
r5596:84985796bbd9
r5596:84985796bbd9
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r2851:45eec56fdf44
r5596:84985796bbd9
r6332:7393965b5322
r1484:58a94337283a
r1484:58a94337283a
r1484:58a94337283a
r1487:755a14bc5e12
r1484:58a94337283a
r1484:58a94337283a
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=UTF-8" http-equiv="content-type">
  <meta name="Description" content="Structure of OpenTTD (OTTD) landscape arrays #2">
  <title>OpenTTD Landscape Internals - #2</title>
  <style type="text/css">
    span.abuse { font-family: "Courier New", Courier, mono; background-color: rgb(255, 58, 31); }
    span.free  { font-family: "Courier New", Courier, mono; background-color: rgb(30, 178, 54); }
    span.used  { font-family: "Courier New", Courier, mono; }
    td.bits    { white-space: nowrap; text-align: center; font-family: "Courier New", Courier, mono; }
    td.caption { white-space: nowrap; text-align: left; }
    td li      { white-space: nowrap; text-align: left; }
    th         { white-space: nowrap; text-align: center; }
  </style>
</head>
<body style="direction: ltr;">
<h3 style="font-weight: bold;">Landscape</h3>
<span style="font-weight: bold;"></span>Six attributes hold the information about a tile.
This can be seen in the <a href="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.
<ul>
  <li><span style="font-weight: bold;"><span class="free">O</span></span> - bit is free</li>
  <li><span style="font-weight: bold;"><span class="used">X</span></span> - bit is used</li>
  <li><span style="font-weight: bold;"><span class="abuse">&nbsp;</span></span> - bit of attribute is abused for different purposes</li>
</ul>
<p>
<ul>
  <li><span style="font-weight: bold;">type_height</span> - 8 bits in size, stores tile height (lower 4 bits) and tile class (upper 4 bits)</li>
  <li><span style="font-weight: bold;">m1</span> - 8 bits in size, used to identify the owner of that tile (eg piece of rail, bridge, etc.)</li>
  <li><span style="font-weight: bold;">m2</span> - 16 bits in size, used to identify the index of the given tile (object) in the (object-)array</li>
  <li><span style="font-weight: bold;">m3</span> - 8 bits in size, is used for general storage</li>
  <li><span style="font-weight: bold;">m4</span> - 8 bits in size, is used for general storage</li>
  <li><span style="font-weight: bold;">m5</span> - 8 bits in size, is used for general storage</li>
  <li><span style="font-weight: bold;">m6</span> - 8 bits in size, special meaning : lower 2 bits only valid in tropic climate, upper 2 bits for bridges</li>
  <li><span style="font-weight: bold;">m7</span> - 8 bits in size, is used for general storage</li>
</ul>

<table align=center border="1" cellpadding="2" cellspacing="2">
  <tbody>
    <tr>
      <th colspan=2>class</th>
      <th>type_height (8)</th>
      <th>m1 (8)</th>
      <th>m2 (16)</th>
      <th>m3 (8)</th>
      <th>m4 (8)</th>
      <th>m5 (8)</th>
      <th>m6 (8)</th>
      <th>m7 (8)</th>
    </tr>
    <tr>
      <td colspan=2 class="caption">bits</td>
      <td class="bits">7654 3210</td>
      <td class="bits">7654 3210</td>
      <td class="bits">FEDC BA98 7654 3210</td>
      <td class="bits">7654 3210</td>
      <td class="bits">7654 3210</td>
      <td class="bits">7654 3210</td>
      <td class="bits">7654 3210</td>
      <td class="bits">7654 3210</td>
    </tr>
    <tr>
      <td rowspan="2">0</td>
      <td class="caption">ground</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO OOOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits">XXXX XX<span class="free">OO</span></td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td class="caption">farmland</td>
      <td class="bits">-inherit-</td>
      <td class="bits">-inherit-</td>
      <td class="bits">XXXX XXXX XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO</span> XXXX</td>
      <td class="bits">-inherit-</td>
      <td class="bits"><span class="free">OOO</span>X XXXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td rowspan=3>1</td>
      <td class="caption">rail</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO</span> XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO O</span>XXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td class="caption">depot</td>
      <td class="bits">-inherit-</td>
      <td class="bits">-inherit-</td>
      <td class="bits"><span class="free">OOOO OOOO OOOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO</span> XXXX</td>
      <td class="bits"><span class="free">OOOO</span> XXXX</td>
      <td class="bits">XX<span class="free">OO O</span>XXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td class="caption">waypoint</td>
      <td class="bits">-inherit-</td>
      <td class="bits">-inherit-</td>
      <td class="bits">XXXX XXXX XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO</span> XXXX</td>
      <td class="bits"><span class="free">OOOO</span> XXXX</td>
      <td class="bits">XX<span class="free">OO O</span>XXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td rowspan=3>2</td>
      <td class="caption">road</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td class="caption">level crossing</td>
      <td class="bits">-inherit-</td>
      <td class="bits">-inherit-</td>
      <td class="bits">-inherit-</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XX<span class="free">OO</span></td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td class="caption">road depot</td>
      <td class="bits">-inherit-</td>
      <td class="bits">-inherit-</td>
      <td class="bits"><span class="free">OOOO OOOO OOOO OOOO</span></td>
      <td class="bits">X<span class="free">OOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td>3</td>
      <td class="caption">house</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX XXXX XXXX</td>
      <td class="bits">XX<span class="free">O</span>X XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XX<span class="abuse">XX XXXX</span></td>
      <td class="bits"><span class="abuse">XXXX XX</span>XX</td>
      <td class="bits"><span class="abuse">X</span>XX<span class="abuse">X XXX</span>X</td>
    </tr>
    <tr>
      <td>4</td>
      <td class="caption">trees</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO</span> XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XX<span class="free">OO</span></td>
      <td class="bits">XX<span class="free">OO O</span>XXX</td>
      <td class="bits"><span class="free">OOOO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td>5</td>
      <td class="caption">station</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO O</span>XXX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td>6</td>
      <td class="caption">water</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO OOOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO OO</span>XX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td rowspan=3>8</td>
      <td class="caption">industry</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="abuse">X</span><span class="free">OO</span><span class="abuse">X
        XXXX</span></td>
      <td class="bits">XXXX XXXX XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td>bubble/sugar/toffee,<BR>
        gold/copper/coal,<BR>
        oil wells, power station</td>
      <td class="bits">-inherit-</td>
      <td class="bits"><span class="abuse">X</span><span class="free">OOO OOOO</span></td>
      <td class="bits">-inherit-</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits">-inherit-</td>
      <td class="bits">-inherit-</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td>toy factory</td>
      <td class="bits">-inherit-</td>
      <td class="bits"><span class="abuse">X</span><span class="free">OOO OOOO</span></td>
      <td class="bits">-inherit-</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">-inherit-</td>
      <td class="bits">-inherit-</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td rowspan=2>9</td>
      <td class="caption">tunnel entrance</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO OOOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO</span> XXXX</td>
      <td class="bits">X<span class="free">OOO OOOO</span></td>
      <td class="bits">X<span class="free">OOO</span> XXXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td>bridge ramp</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO</span> <span class="abuse">XXXX</span>
        <span class="free">OOOO</span></td>
      <td class="bits"><span class="free">OOOO</span> XXXX</td>
      <td class="bits">X<span class="free">OOO OOOO</span></td>
      <td class="bits">X<span class="free">OOO</span> XXXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
    <tr>
      <td>A</td>
      <td class="caption">unmovables</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits"><span class="free">OOOO OOOO OOOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
      <td class="bits">XXXX XXXX</td>
      <td class="bits">XX<span class="free">OO OO</span>XX</td>
      <td class="bits"><span class="free">OOOO OOOO</span></td>
    </tr>
  </tbody>
</table>

</body>
</html>