diff options
Diffstat (limited to 'scene/3d/spring_arm_3d.cpp')
-rw-r--r-- | scene/3d/spring_arm_3d.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/scene/3d/spring_arm_3d.cpp b/scene/3d/spring_arm_3d.cpp index f61e6eb2a7..9775ecc6c6 100644 --- a/scene/3d/spring_arm_3d.cpp +++ b/scene/3d/spring_arm_3d.cpp @@ -54,7 +54,6 @@ void SpringArm3D::_notification(int p_what) { } void SpringArm3D::_bind_methods() { - ClassDB::bind_method(D_METHOD("get_hit_length"), &SpringArm3D::get_hit_length); ClassDB::bind_method(D_METHOD("set_length", "length"), &SpringArm3D::set_length); @@ -84,8 +83,9 @@ float SpringArm3D::get_length() const { } void SpringArm3D::set_length(float p_length) { - if (is_inside_tree() && (Engine::get_singleton()->is_editor_hint() || get_tree()->is_debugging_collisions_hint())) + if (is_inside_tree() && (Engine::get_singleton()->is_editor_hint() || get_tree()->is_debugging_collisions_hint())) { update_gizmo(); + } spring_length = p_length; } @@ -157,7 +157,6 @@ void SpringArm3D::process_spring() { childs_transform.origin = get_global_transform().origin + cast_direction * (spring_length * motion_delta); for (int i = get_child_count() - 1; 0 <= i; --i) { - Node3D *child = Object::cast_to<Node3D>(get_child(i)); if (child) { childs_transform.basis = child->get_global_transform().basis; |