Skip to content

Commit

Permalink
fix stairs direction
Browse files Browse the repository at this point in the history
  • Loading branch information
pablohoch committed Feb 12, 2024
1 parent 8a84abb commit 8d21573
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/routing/costs.cc
Original file line number Diff line number Diff line change
Expand Up @@ -242,8 +242,9 @@ edge_costs get_edge_costs(routing_graph_data const& rg, edge const* e,

if (info->street_type_ == street_type::STAIRS) {
auto const steps = edge_step_count(rg, e);
auto const incline_up = fwd ? info->incline_up_ : !info->incline_up_;
auto const& cf =
get_stairs_factor(profile, info->incline_up_, info->handrail_);
get_stairs_factor(profile, incline_up, info->handrail_);
add_factor(cf, steps);
} else if (info->street_type_ == street_type::ESCALATOR) {
add_factor(profile.escalator_cost_, distance);
Expand Down

0 comments on commit 8d21573

Please sign in to comment.