I have a rocket ship mesh and I want to attach a PhysicsThrusterComponent to the exact center of mass. I’ve tried a couple of approaches with mixed results
- In the Components section of the blueprint editor I can see the green sphere that represents the center of mass of the mesh. I can use this to approximately place the thruster in the correct position, but there is room for error.
- There is a GetCenterOfMass blueprint function, but that gives me (0,0,0). This is presumably local coordinates, relative to the center of the mesh itself, not a value that could be used to set an exact position for a child object.
I’m currently using method (1) which mostly works, but it’s not super accurate. Any slight offset will inherently cause the rocket to veer.
Is there some way I can snap the thruster to the exact center of mass of the rocket mesh? Perhaps I can use the value returned by GetCenterOfMass and convert it to a value that the child object can use, like some kind of LocalToWorld transform?