added some missing files
[oweals/minetest.git] / src / tile.h
1 /*
2 Minetest-c55
3 Copyright (C) 2010 celeron55, Perttu Ahola <celeron55@gmail.com>
4
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License along
16 with this program; if not, write to the Free Software Foundation, Inc.,
17 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 */
19
20 #ifndef TILE_HEADER
21 #define TILE_HEADER
22
23 #include "common_irrlicht.h"
24 #include "utility.h"
25
26 // TileID is supposed to be stored in a u16
27
28 enum TileID
29 {
30         TILE_NONE, // Nothing shown
31         TILE_STONE,
32         TILE_WATER,
33         TILE_GRASS,
34         TILE_TREE,
35         TILE_LEAVES,
36         TILE_GRASS_FOOTSTEPS,
37         TILE_MESE,
38         TILE_MUD,
39         TILE_TREE_TOP,
40         TILE_MUD_WITH_GRASS,
41         
42         // Count of tile ids
43         TILES_COUNT
44 };
45
46 // A mapping from tiles to names of cached textures
47 extern const char * g_tile_texture_names[TILES_COUNT];
48
49 // A mapping from tiles to materials
50 // Initialized at run-time.
51 extern video::SMaterial g_tile_materials[TILES_COUNT];
52
53 /*
54         Functions
55 */
56
57 // Initializes g_tile_materials
58 void tile_materials_preload(TextureCache &cache);
59
60 #endif