summaryrefslogtreecommitdiff
path: root/src/pathfinder/yapf/yapf_costbase.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/pathfinder/yapf/yapf_costbase.hpp')
-rw-r--r--src/pathfinder/yapf/yapf_costbase.hpp12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/pathfinder/yapf/yapf_costbase.hpp b/src/pathfinder/yapf/yapf_costbase.hpp
index 29d6c85c2..057c0ae5b 100644
--- a/src/pathfinder/yapf/yapf_costbase.hpp
+++ b/src/pathfinder/yapf/yapf_costbase.hpp
@@ -12,7 +12,14 @@
#ifndef YAPF_COSTBASE_HPP
#define YAPF_COSTBASE_HPP
+/** Base implementation for cost accounting. */
struct CYapfCostBase {
+ /**
+ * Does the given track direction on the given tile yeild an uphill penalty?
+ * @param tile The tile to check.
+ * @param td The track direction to check.
+ * @return True if there's a slope, otherwise false.
+ */
FORCEINLINE static bool stSlopeCost(TileIndex tile, Trackdir td)
{
if (IsDiagonalTrackdir(td)) {
@@ -34,9 +41,4 @@ struct CYapfCostBase {
}
};
-struct CostRailSettings {
- /* look-ahead signal penalty */
-};
-
-
#endif /* YAPF_COSTBASE_HPP */