summaryrefslogtreecommitdiff
path: root/src/newgrf_canal.h
diff options
context:
space:
mode:
authorpeter1138 <peter1138@openttd.org>2007-05-06 18:14:33 +0000
committerpeter1138 <peter1138@openttd.org>2007-05-06 18:14:33 +0000
commit37a873e03ce5301e9d583072700a938ea889e368 (patch)
tree50b4edf6cde355dbf64d36175e883e73d2e37b4a /src/newgrf_canal.h
parentb0e3c0d40aa66880deef9aa56a8f5d5dea92ae67 (diff)
downloadopenttd-37a873e03ce5301e9d583072700a938ea889e368.tar.xz
(svn r9797) -Feature: [NewGRF] Add action 1, 2 and 3 support for canals.
Diffstat (limited to 'src/newgrf_canal.h')
-rw-r--r--src/newgrf_canal.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/newgrf_canal.h b/src/newgrf_canal.h
new file mode 100644
index 000000000..23fb3a9a8
--- /dev/null
+++ b/src/newgrf_canal.h
@@ -0,0 +1,29 @@
+/* $Id$ */
+
+#ifndef NEWGRF_CANAL_H
+#define NEWGRF_CANAL_H
+
+/** List of different canal 'features'.
+ * Each feature gets an entry in the canal spritegroup table */
+enum CanalFeature {
+ CF_WATERSLOPE,
+ CF_LOCKS,
+ CF_DIKES,
+ CF_ICON,
+ CF_DOCKS,
+ CF_END,
+};
+
+
+/** Table of canal 'feature' sprite groups */
+extern const SpriteGroup *_canal_sg[CF_END];
+
+
+/** Lookup the base sprite to use for a canal.
+ * @param feature Which canal feature we want.
+ * @param tile Tile index of canal, if appropriate.
+ * @return Base sprite returned by GRF, or 0 if none.
+ */
+SpriteID GetCanalSprite(CanalFeature feature, TileIndex tile);
+
+#endif /* NEWGRF_CANAL_H */