Why is my raycast hitting the capsule component and not the skeletal mesh?

Any ideas on why my raycast is hitting the capsule component and not the skeletal mesh of the enemy even though I have trace complex set to true?

Hey @ShadowSprite123!

A few questions:

  • Would you mind sharing the code snippet for your raycast? It would go a long way in understanding what you are doing/what may be going wrong.
  • Are you looking specifically for a skeletal mesh component? Your raycast would hit the outermost shell of a target which would be the capsule component, so looking specifically for the skeletal mesh may fix that.

Any additional information you can provide will be a big help in solving your problem.

Don’t worry I fixed it! The problem was that I was using Use Complex Collision as Simple instead of Use Simple Collision as Complex in the physics asset.