summaryrefslogtreecommitdiff
path: root/src/pathfinder/npf
diff options
context:
space:
mode:
Diffstat (limited to 'src/pathfinder/npf')
-rw-r--r--src/pathfinder/npf/npf.cpp4
-rw-r--r--src/pathfinder/npf/npf.h2
-rw-r--r--src/pathfinder/npf/npf_func.h2
3 files changed, 4 insertions, 4 deletions
diff --git a/src/pathfinder/npf/npf.cpp b/src/pathfinder/npf/npf.cpp
index 085a00053..13410a0f5 100644
--- a/src/pathfinder/npf/npf.cpp
+++ b/src/pathfinder/npf/npf.cpp
@@ -1100,7 +1100,7 @@ void InitializeNPF()
_npf_aystar.max_search_nodes = _settings_game.pf.npf.npf_max_search_nodes;
}
-void NPFFillWithOrderData(NPFFindStationOrTileData *fstd, Vehicle *v, bool reserve_path)
+void NPFFillWithOrderData(NPFFindStationOrTileData *fstd, const Vehicle *v, bool reserve_path)
{
/* Ships don't really reach their stations, but the tile in front. So don't
* save the station id for ships. For roadvehs we don't store it either,
@@ -1122,7 +1122,7 @@ void NPFFillWithOrderData(NPFFindStationOrTileData *fstd, Vehicle *v, bool reser
/*** Ships ***/
-Track NPFShipChooseTrack(Ship *v, TileIndex tile, DiagDirection enterdir, TrackBits tracks)
+Track NPFShipChooseTrack(const Ship *v, TileIndex tile, DiagDirection enterdir, TrackBits tracks)
{
NPFFindStationOrTileData fstd;
Trackdir trackdir = v->GetVehicleTrackdir();
diff --git a/src/pathfinder/npf/npf.h b/src/pathfinder/npf/npf.h
index 3beb09391..fcd75db4d 100644
--- a/src/pathfinder/npf/npf.h
+++ b/src/pathfinder/npf/npf.h
@@ -125,7 +125,7 @@ NPFFoundTargetData NPFRouteToDepotTrialError(TileIndex tile, Trackdir trackdir,
NPFFoundTargetData NPFRouteToSafeTile(const struct Train *v, TileIndex tile, Trackdir trackdir, bool override_railtype);
-void NPFFillWithOrderData(NPFFindStationOrTileData *fstd, Vehicle *v, bool reserve_path = false);
+void NPFFillWithOrderData(NPFFindStationOrTileData *fstd, const Vehicle *v, bool reserve_path = false);
/*
diff --git a/src/pathfinder/npf/npf_func.h b/src/pathfinder/npf/npf_func.h
index 4d38d5807..ef3b1001c 100644
--- a/src/pathfinder/npf/npf_func.h
+++ b/src/pathfinder/npf/npf_func.h
@@ -20,6 +20,6 @@
* @param tracks available tracks on the new tile (to choose from)
* @return the best trackdir for next turn or INVALID_TRACK if the path could not be found
*/
-Track NPFShipChooseTrack(class Ship *v, TileIndex tile, DiagDirection enterdir, TrackBits tracks);
+Track NPFShipChooseTrack(const Ship *v, TileIndex tile, DiagDirection enterdir, TrackBits tracks);
#endif /* NPF_FUNC_H */