OpenTTD

- Main Page
- Related Pages
- Modules
- Namespaces
- Data Structures
- Files

- File List
- Globals

tile_type.h
Go to the documentation of this file.
1 /* $Id: tile_type.h 27148 2015-02-14 12:53:07Z frosch $ */
2
3 /*
4 * This file is part of OpenTTD.
5 * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
6 * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
7 * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
8 */
9
12 #ifndef TILE_TYPE_H
13 #define TILE_TYPE_H
14
15 static const uint TILE_SIZE = 16;
16 static const uint TILE_UNIT_MASK = TILE_SIZE - 1;
17 static const uint TILE_PIXELS = 32;
18 static const uint TILE_HEIGHT = 8;
19
20 static const uint MAX_BUILDING_PIXELS = 200;
21
22 static const uint MAX_TILE_HEIGHT = 255;
23
24 static const uint MIN_MAX_HEIGHTLEVEL = 15;
25 static const uint DEF_MAX_HEIGHTLEVEL = 30;
26 static const uint MAX_MAX_HEIGHTLEVEL = MAX_TILE_HEIGHT;
27
28 static const uint MIN_SNOWLINE_HEIGHT = 2;
29 static const uint DEF_SNOWLINE_HEIGHT = 15;
30 static const uint MAX_SNOWLINE_HEIGHT = (MAX_TILE_HEIGHT - 2);
31
32
40 enum TileType {
41 MP_CLEAR,
42 MP_RAILWAY,
43 MP_ROAD,
44 MP_HOUSE,
45 MP_TREES,
46 MP_STATION,
47 MP_WATER,
48 MP_VOID,
49 MP_INDUSTRY,
50 MP_TUNNELBRIDGE,
51 MP_OBJECT,
52 };
53
69 enum TropicZone {
70 TROPICZONE_NORMAL = 0,
71 TROPICZONE_DESERT = 1,
72 TROPICZONE_RAINFOREST = 2,
73 };
74
78 typedef uint32 TileIndex;
79
83 static const TileIndex INVALID_TILE = (TileIndex)-1;
84
85 #endif /* TILE_TYPE_H */