// Copyright (c) 2012-2023 Wojciech Figat. All rights reserved. using FlaxEngine; namespace FlaxEditor.SceneGraph.Actors { /// /// Scene tree node for actor type. /// [HideInEditor] public sealed class JointNode : ActorNode { /// public JointNode(Actor actor) : base(actor) { } /// public override void PostConvert(ActorNode source) { base.PostConvert(source); if (source.Actor is Joint other) { // Preserve basic properties when changing joint type var joint = (Joint)Actor; joint.Target = other.Target; joint.TargetAnchor = other.TargetAnchor; joint.TargetAnchorRotation = other.TargetAnchorRotation; joint.EnableCollision = other.EnableCollision; } } } }