Can you change collision for single bone at runtime?

As you can see on the picture I would like to change the marked "collision response"on the fly in-game…For the highlighted bones only.

Problem is If i keep it on i get unwanted collisions, but if i turn it off i don’t get the required hit event.
Doing it this way would reduce game complexity as opposed to spawning temporary trigers.


A quick review of the USkeletalMesh api doesn’t include much on collision. USkeletalMesh components do have an associated UPhysicsAsset, and that has some methods related to collision, but nothing that is particularly suited to you.

  1. A dirty way to have what you want is to only have complex collision through the skeletal mesh, and hide the specific bones you want by setting the scale to zero. Then have separate skeletal mesh components appear where hidden bones where. These separate skel meshes don’t have collision.

  2. A clean way would be to have 2 separate UPhysicsAsset for the whole skel mesh, and change between them as needed.

However, I believe this all way too complicated, and its probably easier to consider the bones in the FHitResults. (I assume you are generating a result list from an sweep.). Its better to be cognizant about how you are handling your collisions than engineering a solution that requires you to changing between UPhysicsAssets…

I was sceptical about the second method, but it does work…Changing the UPhysicsAsset in game doesn’t break or stutter the animations at all, so it will suffice for now.

Filtering hit results is N/A for my case.

I also tried the function to Terminate physics Body below, works fine but you can’t bring collision back easily.