Announcement

Collapse
No announcement yet.

4.22.2 Attach Actor in Editor not working correctly? Does not snap to socket

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    4.22.2 Attach Actor in Editor not working correctly? Does not snap to socket

    Anyone notice if you:

    - right click an actor
    - select Attach To >> another Actor >> select Socket

    In 4.20 it no longer snaps the attached actor to the socket location?

    Is there a setting that was added? Seems like the default use case should snap the attached object to the socket location ...

    EDIT: this is still broken in 4.22.2.
    Last edited by Shmoopy1701; 06-17-2019, 02:43 PM.

    #2
    Sorry if this has already been tracked down, but figured out what broke attaching.

    Engine >> Source >> Editor >> UnrealEd >> Private >> EditorEngine::ParentActors()

    Old code:

    Code:
    // Snap to socket if a valid socket name was provided, otherwise attach without changing the relative transform
    const bool bValidSocketName = !SocketName.IsNone() && ParentRoot->DoesSocketExist(SocketName);
    ChildRoot->AttachToComponent(ParentRoot, bValidSocketName ? FAttachmentTransformRules::SnapToTargetNotIncludingScale : FAttachmentTransformRules::KeepWorldTransform, SocketName);
    4.20 code:

    Code:
    // Snap to socket if a valid socket name was provided, otherwise attach without changing the relative transform
    ChildRoot->AttachToComponent(ParentRoot, FAttachmentTransformRules::KeepWorldTransform, SocketName);
    Seems unintended since the comment does not match what the code does now.

    Comment


      #3
      Hey Man,

      I've been having the same issue with mine. I tried changing the code to the old version but it didn't seem to work (maybe cause I'm not running a C++ source version).

      Did you ever manage to do something that makes the snap to sockets work like it used to?

      Thanks

      Comment


        #4
        Yes. Changed the source code above and recompiled the engine. Its been 2 version and still seems broken. Not snapping to socket is the more rare use case. Not sure what the reasoning behind this is ...

        What you can do is attach the actor, go to details, and zero out the relative transform.
        Last edited by Shmoopy1701; 06-18-2019, 08:39 AM.

        Comment


          #5
          Hey Jocko Jonson - Did you submit a bug report? It would help our team track this issue!

          Comment


            #6
            Originally posted by Amanda.Bott View Post
            Hey Jocko Jonson - Did you submit a bug report? It would help our team track this issue!
            No but I will now.

            Comment


              #7
              Great, thank you so much!

              Comment


                #8
                Is this solved? I don't think so right now... Even though we are in 4.22.3

                Does someone know where the concrete bug report is, so I can give it an upvote?


                Is it possible to work around this issue? Because setting the relative transforms to zero, after attaching, does not work either.

                Thanks!

                Comment


                  #9
                  I believe this is the issue you're looking at: https://issues.unrealengine.com/issue/UE-59094. It appears to be punted to 4.24.

                  Comment


                    #10
                    Originally posted by Amanda.Bott View Post
                    I believe this is the issue you're looking at: https://issues.unrealengine.com/issue/UE-59094. It appears to be punted to 4.24.
                    Thanks Amanda.

                    On a side note, surprising how few people are attaching actors to other actors in the editor.

                    Comment

                    Working...
                    X