diff options
author | yexo <yexo@openttd.org> | 2009-03-28 12:04:38 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2009-03-28 12:04:38 +0000 |
commit | 400208ee0afd84f1e9ddf1ab851e34a87b3e98c0 (patch) | |
tree | d96ab887f0146fd83a81a513c794f40959849e14 /src/ai/api/ai_bridge.hpp | |
parent | e02d31cd3abaf078131a82e7d0a0c46a5a759d24 (diff) | |
download | openttd-400208ee0afd84f1e9ddf1ab851e34a87b3e98c0.tar.xz |
(svn r15875) -Add: AIBridge::GetBridgeID() so AIs can get the type of bridge that are already build.
Diffstat (limited to 'src/ai/api/ai_bridge.hpp')
-rw-r--r-- | src/ai/api/ai_bridge.hpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/ai/api/ai_bridge.hpp b/src/ai/api/ai_bridge.hpp index f53ee2339..58cc9d60b 100644 --- a/src/ai/api/ai_bridge.hpp +++ b/src/ai/api/ai_bridge.hpp @@ -52,6 +52,14 @@ public: static bool IsBridgeTile(TileIndex tile); /** + * Get the BridgeID of a bridge at a given tile. + * @param tile The tile to get the BridgeID from. + * @pre IsBridgeTile(tile). + * @return The BridgeID from the bridge at tile 'tile'. + */ + static BridgeID GetBridgeID(TileIndex tile); + + /** * Get the name of a bridge. * @param bridge_id The bridge to get the name of. * @pre IsValidBridge(bridge_id). |