diff options
author | michi_cc <michi_cc@openttd.org> | 2011-12-03 23:40:57 +0000 |
---|---|---|
committer | michi_cc <michi_cc@openttd.org> | 2011-12-03 23:40:57 +0000 |
commit | 0e5e8fff12a3c91f0198afb25c03eb71b2248005 (patch) | |
tree | 235af65c5215b3417adad3be39b39ad8e85208b0 /src/script/api/script_rail.hpp | |
parent | d3b7b89493e025654d218fb77da095649b4f6ba2 (diff) | |
download | openttd-0e5e8fff12a3c91f0198afb25c03eb71b2248005.tar.xz |
(svn r23416) -Add: [NoAI] API for querying infrastructure costs.
Diffstat (limited to 'src/script/api/script_rail.hpp')
-rw-r--r-- | src/script/api/script_rail.hpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/script/api/script_rail.hpp b/src/script/api/script_rail.hpp index b7d7db923..96d673af6 100644 --- a/src/script/api/script_rail.hpp +++ b/src/script/api/script_rail.hpp @@ -464,6 +464,14 @@ public: * To get km/h multiply this number by 1.00584. */ static int32 GetMaxSpeed(RailType railtype); + + /** + * Get the maintenance cost factor of a railtype. + * @param railtype The railtype to get the maintenance factor of. + * @pre IsRailTypeAvailable(railtype) + * @return Maintenance cost factor of the railtype. + */ + static uint16 GetMaintenanceCostFactor(RailType railtype); }; #endif /* SCRIPT_RAIL_HPP */ |