summaryrefslogtreecommitdiff
path: root/scene/3d/soft_dynamic_body_3d.h
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2021-10-21 11:42:44 +0200
committerGitHub <noreply@github.com>2021-10-21 11:42:44 +0200
commit8688b97dda57bec8083870a2e2c4c7ca9a021f46 (patch)
tree61086f687ebd69f4c32ab1ec4a82089e4db0a446 /scene/3d/soft_dynamic_body_3d.h
parent351d378b03e244e91c39ab90d564989cb3c933ca (diff)
parent1f816979f6f30e09d8bf68d163775e1c2b105551 (diff)
Merge pull request #54036 from nekomatata/fix-soft-body-memory-corruption
Diffstat (limited to 'scene/3d/soft_dynamic_body_3d.h')
-rw-r--r--scene/3d/soft_dynamic_body_3d.h15
1 files changed, 7 insertions, 8 deletions
diff --git a/scene/3d/soft_dynamic_body_3d.h b/scene/3d/soft_dynamic_body_3d.h
index 5e7fbfe29e..57e116aa05 100644
--- a/scene/3d/soft_dynamic_body_3d.h
+++ b/scene/3d/soft_dynamic_body_3d.h
@@ -90,7 +90,7 @@ private:
DisableMode disable_mode = DISABLE_MODE_REMOVE;
- bool mesh_owner = false;
+ RID owned_mesh;
uint32_t collision_mask = 1;
uint32_t collision_layer = 1;
NodePath parent_collision_ignore;
@@ -106,6 +106,12 @@ private:
void _update_pickable();
+ void _update_physics_server();
+ void _draw_soft_mesh();
+
+ void _prepare_physics_server();
+ void _become_mesh_owner();
+
protected:
bool _set(const StringName &p_name, const Variant &p_value);
bool _get(const StringName &p_name, Variant &r_ret) const;
@@ -120,14 +126,7 @@ protected:
TypedArray<String> get_configuration_warnings() const override;
-protected:
- void _update_physics_server();
- void _draw_soft_mesh();
-
public:
- void prepare_physics_server();
- void become_mesh_owner();
-
RID get_physics_rid() const { return physics_rid; }
void set_collision_mask(uint32_t p_mask);