diff options
Diffstat (limited to 'scene/resources/convex_polygon_shape_3d.cpp')
-rw-r--r-- | scene/resources/convex_polygon_shape_3d.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/scene/resources/convex_polygon_shape_3d.cpp b/scene/resources/convex_polygon_shape_3d.cpp index ec9ab68015..affeb05a8f 100644 --- a/scene/resources/convex_polygon_shape_3d.cpp +++ b/scene/resources/convex_polygon_shape_3d.cpp @@ -33,13 +33,11 @@ #include "servers/physics_server_3d.h" Vector<Vector3> ConvexPolygonShape3D::get_debug_mesh_lines() { - Vector<Vector3> points = get_points(); if (points.size() > 3) { - Vector<Vector3> varr = Variant(points); - Geometry::MeshData md; + Geometry3D::MeshData md; Error err = QuickHull::build(varr, md); if (err == OK) { Vector<Vector3> lines; @@ -66,25 +64,21 @@ real_t ConvexPolygonShape3D::get_enclosing_radius() const { } void ConvexPolygonShape3D::_update_shape() { - PhysicsServer3D::get_singleton()->shape_set_data(get_shape(), points); Shape3D::_update_shape(); } void ConvexPolygonShape3D::set_points(const Vector<Vector3> &p_points) { - points = p_points; _update_shape(); notify_change_to_owners(); } Vector<Vector3> ConvexPolygonShape3D::get_points() const { - return points; } void ConvexPolygonShape3D::_bind_methods() { - ClassDB::bind_method(D_METHOD("set_points", "points"), &ConvexPolygonShape3D::set_points); ClassDB::bind_method(D_METHOD("get_points"), &ConvexPolygonShape3D::get_points); |