Skip to content

Commit

Permalink
way_net: fix most waypoints not being included in _m_name_to_waypoint
Browse files Browse the repository at this point in the history
This was found due to 0f58174 in response
to #30 which proposes changing the `way_net::waypoint` API to take a
`std::string_view` instead of a `const std::string&`.
  • Loading branch information
lmichaelis committed Nov 6, 2022
1 parent 0f58174 commit c8010e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion source/world/way_net.cc
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ namespace phoenix {
auto& new_wp = net.waypoints.emplace_back();
read_waypoint_data(new_wp, in);
new_wp.free_point = false;

net._m_name_to_waypoint[new_wp.name] = net.waypoints.size() - 1;
obj_id_to_wp[obj.index] = net.waypoints.size() - 1;
wp = net.waypoints.size() - 1;
} else {
Expand Down

0 comments on commit c8010e1

Please sign in to comment.