diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2023-03-10 14:06:38 +0100 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2023-03-10 14:06:38 +0100 |
commit | 0c59e0c35b86680def0c1d2b572ee88657e10066 (patch) | |
tree | 19f30c393e33e6ac5d89c5ef66d259a038b5c220 /servers/extensions | |
parent | fcbb3e638830f9a4340ec238af6004a868f40bef (diff) | |
parent | 1bad2e30eee2cb6b9751cfa49a92583881f54c7e (diff) | |
download | redot-engine-0c59e0c35b86680def0c1d2b572ee88657e10066.tar.gz |
Merge pull request #74707 from mihe/recovery-as-collision
Add `recovery_as_collision` to extension binding of `_body_test_motion`
Diffstat (limited to 'servers/extensions')
-rw-r--r-- | servers/extensions/physics_server_3d_extension.cpp | 2 | ||||
-rw-r--r-- | servers/extensions/physics_server_3d_extension.h | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/servers/extensions/physics_server_3d_extension.cpp b/servers/extensions/physics_server_3d_extension.cpp index bea9abf328..997daaa9f2 100644 --- a/servers/extensions/physics_server_3d_extension.cpp +++ b/servers/extensions/physics_server_3d_extension.cpp @@ -298,7 +298,7 @@ void PhysicsServer3DExtension::_bind_methods() { GDVIRTUAL_BIND(_body_set_ray_pickable, "body", "enable"); - GDVIRTUAL_BIND(_body_test_motion, "body", "from", "motion", "margin", "max_collisions", "collide_separation_ray", "result"); + GDVIRTUAL_BIND(_body_test_motion, "body", "from", "motion", "margin", "max_collisions", "collide_separation_ray", "recovery_as_collision", "result"); GDVIRTUAL_BIND(_body_get_direct_state, "body"); diff --git a/servers/extensions/physics_server_3d_extension.h b/servers/extensions/physics_server_3d_extension.h index 6c5dd38714..a9d04b1f05 100644 --- a/servers/extensions/physics_server_3d_extension.h +++ b/servers/extensions/physics_server_3d_extension.h @@ -382,7 +382,7 @@ public: EXBIND2(body_set_ray_pickable, RID, bool) - GDVIRTUAL7RC(bool, _body_test_motion, RID, const Transform3D &, const Vector3 &, real_t, int, bool, GDExtensionPtr<PhysicsServer3DExtensionMotionResult>) + GDVIRTUAL8RC(bool, _body_test_motion, RID, const Transform3D &, const Vector3 &, real_t, int, bool, bool, GDExtensionPtr<PhysicsServer3DExtensionMotionResult>) thread_local static const HashSet<RID> *exclude_bodies; thread_local static const HashSet<ObjectID> *exclude_objects; @@ -394,7 +394,7 @@ public: bool ret = false; exclude_bodies = &p_parameters.exclude_bodies; exclude_objects = &p_parameters.exclude_objects; - GDVIRTUAL_REQUIRED_CALL(_body_test_motion, p_body, p_parameters.from, p_parameters.motion, p_parameters.margin, p_parameters.max_collisions, p_parameters.collide_separation_ray, r_result, ret); + GDVIRTUAL_REQUIRED_CALL(_body_test_motion, p_body, p_parameters.from, p_parameters.motion, p_parameters.margin, p_parameters.max_collisions, p_parameters.collide_separation_ray, p_parameters.recovery_as_collision, r_result, ret); exclude_bodies = nullptr; exclude_objects = nullptr; return ret; |