Navigation
API > API/Plugins > API/Plugins/PhysicsControl > API/Plugins/PhysicsControl/UPhysicsControlComponent
References
| Module | PhysicsControl |
| Header | /Engine/Plugins/Experimental/PhysicsControl/Source/PhysicsControl/Public/PhysicsControlComponent.h |
| Include | #include "PhysicsControlComponent.h" |
| Source | /Engine/Plugins/Experimental/PhysicsControl/Source/PhysicsControl/Private/PhysicsControlComponent.cpp |
UFUNCTION&40;BlueprintCallable, Category&61;PhysicsControl&41;
TMap< FName, FPhysicsControlNames > CreateControlsFromLimbBonesAndConstraintProfile
&40;
FPhysicsControlNames & AllControls,
const TMap< FName, FPhysicsControlLimbBones > & LimbBones,
const FName ConstraintProfile,
const bool bEnabled
&41;
Remarks
Creates a collection of ParentSpace controls controlling a skeletal mesh, grouped together in limbs, initializing them with a constraint profile A map containing the controls for each limb
Parameters
| Name | Description |
|---|---|
| AllControls | A single container for all the controls that have been created |
| LimbBones | A map relating the limbs and the bones that they contain. Typically create this using GetLimbBonesFromSkeletalMesh |
| ConstraintProfile | The constraint profile to use for initializing the control strength and damping (etc) parameters. Note that the controls will all be created in " parent space" - i.e. with each part controlled relative to its parent. The strength and damping will be taken from the values that the relevant joint in the physics asset would have given the constraint profile (or the default profile if it can't be found) - though they will not match exactly if the linear drive and different x/y/z values, or if the angular drive was using twist/swing instead of slerp. Note also that the joint constraints do not use the animation velocity as a target, so when creating controls in this way the control settings will set the skeletal animation velocity multiplier to zero. |
| bEnabled | If true then the control will be enabled immediately. If false you will need to call SetControlEnabled(true) in order to enable it. |