summaryrefslogtreecommitdiff
path: root/src/tunnel_map.h
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2007-05-20 19:14:08 +0000
committerrubidium <rubidium@openttd.org>2007-05-20 19:14:08 +0000
commitd86b5e5e9328e85faa1bf97615b8c796fc874863 (patch)
tree040143187639f8855d9618bfc8f784f4a42bbaeb /src/tunnel_map.h
parentc685a7179f58e8df5e64b424d4f320723e07b65c (diff)
downloadopenttd-d86b5e5e9328e85faa1bf97615b8c796fc874863.tar.xz
(svn r9892) -Codechange: lots of ground work for allowing multiple types of "road" with multiple owners on a single tile.
Diffstat (limited to 'src/tunnel_map.h')
-rw-r--r--src/tunnel_map.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/tunnel_map.h b/src/tunnel_map.h
index dde7bac63..66d5bcd10 100644
--- a/src/tunnel_map.h
+++ b/src/tunnel_map.h
@@ -9,6 +9,7 @@
#include "macros.h"
#include "map.h"
#include "rail.h"
+#include "road.h"
/**
* Is this a tunnel (entrance)?
@@ -93,13 +94,14 @@ bool IsTunnelInWay(TileIndex, uint z);
* @param t the entrance of the tunnel
* @param o the owner of the entrance
* @param d the direction facing out of the tunnel
+ * @param r the road type used in the tunnel
*/
-static inline void MakeRoadTunnel(TileIndex t, Owner o, DiagDirection d)
+static inline void MakeRoadTunnel(TileIndex t, Owner o, DiagDirection d, RoadTypes r)
{
SetTileType(t, MP_TUNNELBRIDGE);
SetTileOwner(t, o);
_m[t].m2 = 0;
- _m[t].m3 = 0;
+ _m[t].m3 = r;
_m[t].m4 = 0;
_m[t].m5 = TRANSPORT_ROAD << 2 | d;
}