Navigation
API > API/Editor > API/Editor/SkeletalMeshEditor > API/Editor/SkeletalMeshEditor/USkeletalMeshEditorSubsystem
Description
Assigns a PhysicsAsset to the given SkeletalMesh if it is compatible. Passing nullptr / None as the physics asset will always succeed and will clear the physics asset assignment for the target SkeletalMesh
| Name | AssignPhysicsAsset |
| Type | function |
| Header File | /Engine/Source/Editor/SkeletalMeshEditor/Public/SkeletalMeshEditorSubsystem.h |
| Include Path | #include "SkeletalMeshEditorSubsystem.h" |
| Source | /Engine/Source/Editor/SkeletalMeshEditor/Private/SkeletalMeshEditorSubsystem.cpp |
UFUNCTION (BlueprintCallable, Category="Editor Scripting | SkeletalMesh")
static bool AssignPhysicsAsset
(
USkeletalMesh * TargetMesh,
UPhysicsAsset * PhysicsAsset
)
Whether the physics asset was successfully assigned to the mesh
Parameters
| Name | Remarks |
|---|---|
| TargetMesh | The mesh to attempt to assign the PhysicsAsset to |
| PhysicsAsset | The physics asset to assign to the provided mesh (or nullptr/None) |