AttachTo + ChildActorComponent breaks on static mesh actor BPs with physics enabled

This seems suspiciously similar to parts of what was reported in https://answers.unrealengine.com/questions/232013/collision-and-child-actor.html and https://answers.unrealengine.com/questions/248957/attachto-not-working-on-uspherecomponent.html – especially the latter.

The boil-down of it is that if I create a (moveable) static mesh actor BP that has physics enabled, and then try to use it by calling AddChildActorComponent + AttachTo targeting the scene default root, the AttachTo appears to completely ignore(?) its transform handling option, and treat it as if it were “keep world position”.

Steps to reproduce:

  1. Create a BP extending StaticMeshActor
  2. Set the BP defaults to be movable, enable physics, and set the collision presents accordingly
  3. Add a tick event handler that applies a physics force (torque is the main one I’ve tried at this point)
  4. Create a BP extending Pawn
  5. Add an event handler for play begin
  6. To that event handler, add an AddChildActorComponent node set for manual attachment and a non-zero transform vector
  7. Then add a node which attempts to attach that component to the scene default component, set to keep relative transform
  8. Place an instance of the pawn BP into a level at some position other than the origin, and hit play

Expected result: the pawn should spawn into the level, with the static mesh BP offset from the pawn origin by the transform vector specified in step 6, in all cases

Actual result:

  • If the static mesh actor BP has physics disabled, it is spawned in the correct location
  • If the static mesh actor BP has physics enabled, it is spawned at that offset from the world origin, rather than the pawn’s origin

I have a sample project that demonstrates this in multiple ways, but I wasn’t able to find a good guide for “how to provide an example project sanely” anywhere – if someone can point me at instructions for that, I will attach it.

Of course, upon posting the question, the “similar questions” sidebar comes up with ChildActor with physics spawns in incorrect location - World Creation - Unreal Engine Forums which appears to quite possibly be identical.

Why that never came up when I was searching for answers in the first place, I have no idea, but it didn’t.

Hi JAelwyn,

Yes, I believe you’re experiencing the same issue reported in this post (reported as UE-18762 in our bug tracking system). I’ve updated the bug with your notes and I’ll post here if I see an update on it.

For future reference, the best way to get a test project to us is to upload it someplace like Dropbox or Google Drive and then post a link for us.