src/newgrf_canal.h
author translators
Mon, 15 Dec 2008 11:39:23 +0000
changeset 10424 99036ab7085e
parent 9750 7114408dd1fa
permissions -rw-r--r--
(svn r14677) -Update: WebTranslator2 update to 2008-12-15 11:38:07
arabic_egypt - 343 fixed, 3 changed by Azoo4oozi (153), khaloofah (193)
indonesian - 123 changed by adjayanto (95), fanioz (28)
macedonian - 74 fixed, 4 changed by sashozs (78)
simplified_chinese - 8 fixed by ww9980 (8)
traditional_chinese - 6 fixed by ww9980 (6)
/* $Id$ */

/** @file newgrf_canal.h Handling of NewGRF canals. */

#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_RIVER_SLOPE,
	CF_RIVER_EDGE,
	CF_END,
};


struct WaterFeature {
	const SpriteGroup *group;
	const GRFFile *grffile;   ///< newgrf where 'group' belongs to
	uint8 callbackmask;
	uint8 flags;
};


/** Table of canal 'feature' sprite groups */
extern WaterFeature _water_feature[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 */