You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-24 15:26:15 +00:00
Replace Navigation std::vector use with LocalVector
Replace Navigation std::vector use with LocalVector.
This commit is contained in:
@@ -34,7 +34,7 @@
|
||||
#include "core/math/vector3.h"
|
||||
#include "core/templates/hash_map.h"
|
||||
#include "core/templates/hashfuncs.h"
|
||||
#include "core/templates/vector.h"
|
||||
#include "core/templates/local_vector.h"
|
||||
#include <vector>
|
||||
|
||||
class NavRegion;
|
||||
@@ -96,13 +96,13 @@ struct Polygon {
|
||||
NavRegion *owner = nullptr;
|
||||
|
||||
/// The points of this `Polygon`
|
||||
std::vector<Point> points;
|
||||
LocalVector<Point> points;
|
||||
|
||||
/// Are the points clockwise ?
|
||||
bool clockwise;
|
||||
|
||||
/// The edges of this `Polygon`
|
||||
std::vector<Edge> edges;
|
||||
LocalVector<Edge> edges;
|
||||
|
||||
/// The center of this `Polygon`
|
||||
Vector3 center;
|
||||
@@ -124,6 +124,8 @@ struct NavigationPoly {
|
||||
/// The distance to the destination.
|
||||
float traveled_distance = 0.0;
|
||||
|
||||
NavigationPoly() { poly = nullptr; }
|
||||
|
||||
NavigationPoly(const Polygon *p_poly) :
|
||||
poly(p_poly) {}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user