diff --git a/src/bridge.h b/src/bridge.h --- a/src/bridge.h +++ b/src/bridge.h @@ -28,6 +28,11 @@ extern const Bridge orig_bridge[MAX_BRID 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 */