Skip to content

Commit

Permalink
Bugfix random node (#22)
Browse files Browse the repository at this point in the history
- Bugfix
  • Loading branch information
bilalkah authored Oct 28, 2023
1 parent 2d0cf1a commit 1ab0093
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions planning/tree_base/src/common_tree_base.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ Node RandomNode(const std::shared_ptr<Map> map)
{
auto random_point{RandomSampling()};
random_node =
Node(static_cast<int>(random_point.first * map->GetWidth()),
static_cast<int>(random_point.second * map->GetHeight()));
Node(static_cast<int>(random_point.first * map->GetHeight()),
static_cast<int>(random_point.second * map->GetWidth()));
if (map->GetNodeState(random_node) == NodeState::kFree)
{
is_valid = true;
Expand Down

0 comments on commit 1ab0093

Please sign in to comment.