From 8047d84aa04a65bb4c63fe44f8b01e1979246689 Mon Sep 17 00:00:00 2001 From: rubidium Date: Fri, 27 Aug 2010 10:42:48 +0000 Subject: [PATCH] (svn r20633) -Cleanup: and clarify some bits in the landscape documentation and make them pass the validator again. --- docs/landscape.html | 113 +++++++++++++++++++++------------- docs/landscape_externals.html | 2 +- docs/landscape_grid.html | 2 +- 3 files changed, 72 insertions(+), 45 deletions(-) diff --git a/docs/landscape.html b/docs/landscape.html index af35fb0bc6..a019888100 100644 --- a/docs/landscape.html +++ b/docs/landscape.html @@ -4,64 +4,90 @@ - + OpenTTD Landscape Internals

Landscape

+

+ For a graphical representation of the tile-layout have a look at + Landscape grid page. +

Eight attributes (counting "type_height") hold the informations about a tile.
These attributes are referred to as - "type_height", - "m1", "m2", - "m3", "m4", - "m5", "m6" - and "m7".
+ "type_height", + "m1", "m2", + "m3", "m4", + "m5", "m6" + and "m7".
The most important value is the class of a tile, stored in the upper 4 bits of the type_height attribute. The lower 4 bits are used to encode the height and slope data.

- Special Attribute : m6. There are 4 bits of it that are used accross multiple tile classes
+ Frequently repeating patterns: -

- For a graphical representation of the tile-layout have a look at - Landscape grid page. -

- - The owner of a tile, as frequently associated with attribute m1 bits 4..0, - can be either companies (human or AI) or "Game entities". - They are identified using: - - - - - - -
00..0E  Normal companies
0F  a town owns the tile
10  nobody owns the tile
11  "water" owns the tile
FF  spectator in MP or in scenario editor

OTTD's class-specific periodic tile processing routine is called once every +256 ticks for each tile.

@@ -708,7 +734,7 @@ - Newhouses is the name englobing a newGRF feature developped by TTDPatch devs (mainly Csaboka).
+
Newhouses is the name englobing a newGRF feature developped by TTDPatch devs (mainly Csaboka).
It allows the replacement of the properties as well as the graphics of houses in the game.
To distinguish between the standard behaviour and the newGRF one, HouseID (m4 + m3[6]) is tested for anything above 110.
110 is the count of standard houses. So above 110 means there is a new definition of at least one house
@@ -1525,6 +1551,7 @@ 2  water +
  • m5 bits 1..0: direction onto the bridge / out of the tunnel @@ -1569,7 +1596,6 @@
  • m1 bits 6..5 : Water class (sea, canal, river or land)
  • m1 bits 4..0: owner of the object (for lighthouses and transmitters normally 10)
  • m2: index into the array of objects -
  • m3: animation counter
  • m5: tile type:
  • @@ -1600,6 +1626,7 @@
  • m6 bits 7..6 : Possibility of a bridge above, in the direction specified
  • m6 bits 1..0 : Tropic zone definition
  • +
  • m7: animation counter
  • diff --git a/docs/landscape_externals.html b/docs/landscape_externals.html index 16f130532b..cef6c2f2c7 100644 --- a/docs/landscape_externals.html +++ b/docs/landscape_externals.html @@ -4,7 +4,7 @@ - + OpenTTD Landscape externals diff --git a/docs/landscape_grid.html b/docs/landscape_grid.html index 226b999bfd..77cde68b3f 100644 --- a/docs/landscape_grid.html +++ b/docs/landscape_grid.html @@ -1,7 +1,7 @@ - + OpenTTD Landscape Internals - #2