summaryrefslogtreecommitdiff
path: root/src/bridge.h
diff options
context:
space:
mode:
authortron <tron@openttd.org>2007-02-24 18:44:30 +0000
committertron <tron@openttd.org>2007-02-24 18:44:30 +0000
commit5c91ec0587c386e07bb47cc0ccd73538c404e305 (patch)
tree146b581ebbf8fc4698bc401138ae02be14f7992d /src/bridge.h
parentb26ae7f0e76c82488f2a550e69ca2878bdcd97da (diff)
downloadopenttd-5c91ec0587c386e07bb47cc0ccd73538c404e305.tar.xz
(svn r8884) -Fix
Replace SetSpeedLimitOnBridge() by something simpler
Diffstat (limited to 'src/bridge.h')
-rw-r--r--src/bridge.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/bridge.h b/src/bridge.h
index 0a493781d..bf622804d 100644
--- a/src/bridge.h
+++ b/src/bridge.h
@@ -28,6 +28,11 @@ extern const Bridge orig_bridge[MAX_BRIDGES];
extern Bridge _bridge[MAX_BRIDGES];
uint GetBridgeFoundation(Slope tileh, Axis axis);
-uint SetSpeedLimitOnBridge(Vehicle *);
+
+static inline const Bridge *GetBridge(uint i)
+{
+ assert(i < lengthof(_bridge));
+ return &_bridge[i];
+}
#endif /* BRIDGE_H */