Navigation
API > API/Runtime > API/Runtime/Engine > API/Runtime/Engine/Components > API/Runtime/Engine/Components/UPrimitiveComponent
References
| Module | Engine |
| Header | /Engine/Source/Runtime/Engine/Classes/Components/PrimitiveComponent.h |
| Include | #include "Components/PrimitiveComponent.h" |
| Source | /Engine/Source/Runtime/Engine/Private/PrimitiveComponentPhysics.cpp |
void SetCenterOfMass
&40;
FVector CenterOfMassOffset,
FName BoneName
&41;
Remarks
Set the center of mass of a single body. This will offset the physx-calculated center of mass. Note that in the case where multiple bodies are attached together, the center of mass will be set for the entire group.
Parameters
| Name | Description |
|---|---|
| CenterOfMassOffset | User specified offset for the center of mass of this object, from the calculated location. |
| BoneName | If a SkeletalMeshComponent, name of body to set center of mass of. 'None' indicates root body. |