diff options
author | StormBytePP <stormbyte@gmail.com> | 2015-09-14 11:02:24 +0200 |
---|---|---|
committer | StormBytePP <stormbyte@gmail.com> | 2015-09-14 11:02:24 +0200 |
commit | f5dbec368aa392c755749dd1965ffb37f29b4029 (patch) | |
tree | afcdf1f849bff67c541d7a88fa8be7fec2f37e67 | |
parent | db23ad7df2656347652d79d04a2486a8e4950bb5 (diff) |
Removed infinity from custom_weight function, as it was causing problems in path calculation
-rw-r--r-- | src/server/game/Entities/Taxi/TaxiPathGraph.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/server/game/Entities/Taxi/TaxiPathGraph.cpp b/src/server/game/Entities/Taxi/TaxiPathGraph.cpp index 7c6f0c388a4..62d249cc5c0 100644 --- a/src/server/game/Entities/Taxi/TaxiPathGraph.cpp +++ b/src/server/game/Entities/Taxi/TaxiPathGraph.cpp @@ -136,7 +136,7 @@ size_t TaxiPathGraph::GetCompleteNodeRoute(uint32_t sourceNodeID, uint32_t desti try { auto wow_custom_weight_map = boost::make_transform_value_property_map( - [](float w) { return w>MaxFlightDistanceThreshold ? std::numeric_limits<cost>::infinity() : w; }, + [](float w) { return w>MaxFlightDistanceThreshold ? w*1000 : w; }, boost::get(boost::edge_weight, m_graph) ); boost::astar_search(m_graph, start, |