diff options
Diffstat (limited to 'core/math/a_star.h')
-rw-r--r-- | core/math/a_star.h | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/core/math/a_star.h b/core/math/a_star.h index a6fa771b30..7cfa73f2c2 100644 --- a/core/math/a_star.h +++ b/core/math/a_star.h @@ -47,20 +47,20 @@ class AStar : public Reference { struct Point { Point() {} - int id; + int id = 0; Vector3 pos; - real_t weight_scale; - bool enabled; + real_t weight_scale = 0; + bool enabled = false; OAHashMap<int, Point *> neighbours = 4u; OAHashMap<int, Point *> unlinked_neighbours = 4u; // Used for pathfinding. - Point *prev_point; - real_t g_score; - real_t f_score; - uint64_t open_pass; - uint64_t closed_pass; + Point *prev_point = nullptr; + real_t g_score = 0; + real_t f_score = 0; + uint64_t open_pass = 0; + uint64_t closed_pass = 0; }; struct SortPoints { |