Location-based colliders on animated models

Hi all,

I need an effect similar to headshot/location-based damage, where colliders are placed on a model and checked using raytracing to see if something connects with them. The way I’m doing this right now is to make empty game objects, give them box colliders, and child them to the object I want the location-based stuff on, e.g. the model.

This is fine until I animate them. Now the head, etc. is moving, but the collider doesn’t have a reference point to move with it. Any suggestions for how I can keep the colliders in the same place relative to the model?

The method you’re using at the moment should work fine - animated objects in Unity have their bone hierarchy converted to GameObjects.

Once you’ve got the rigged object placed in the scene, you should be able to expand its bones in the hierarchy tab until you find the one you want, then parent your collider to it.