10 #include "bridge_map.h" |
10 #include "bridge_map.h" |
11 |
11 |
12 /* ground type, m5 bits 2...4 |
12 /* ground type, m5 bits 2...4 |
13 * valid densities (bits 0...1) in comments after the enum |
13 * valid densities (bits 0...1) in comments after the enum |
14 */ |
14 */ |
15 typedef enum ClearGround { |
15 enum ClearGround { |
16 CLEAR_GRASS = 0, ///< 0-3 |
16 CLEAR_GRASS = 0, ///< 0-3 |
17 CLEAR_ROUGH = 1, ///< 3 |
17 CLEAR_ROUGH = 1, ///< 3 |
18 CLEAR_ROCKS = 2, ///< 3 |
18 CLEAR_ROCKS = 2, ///< 3 |
19 CLEAR_FIELDS = 3, ///< 3 |
19 CLEAR_FIELDS = 3, ///< 3 |
20 CLEAR_SNOW = 4, ///< 0-3 |
20 CLEAR_SNOW = 4, ///< 0-3 |
21 CLEAR_DESERT = 5 ///< 1,3 |
21 CLEAR_DESERT = 5 ///< 1,3 |
22 } ClearGround; |
22 }; |
23 |
23 |
24 |
24 |
25 static inline ClearGround GetClearGround(TileIndex t) |
25 static inline ClearGround GetClearGround(TileIndex t) |
26 { |
26 { |
27 assert(IsTileType(t, MP_CLEAR)); |
27 assert(IsTileType(t, MP_CLEAR)); |