How to prevent the player from clipping through static meshes?

Hello everyone! I’m using the Character Blueprint provided by the Game Animation Sample in Unreal Engine 5.4.4, modifying it to make it first-person and enabling crouch. The camera is managed via a Spring Arm to which it’s attached, and the spring arm references the head socket bone for head movement (Bobbing View).

The problem
However, when I sprint toward a static mesh or crouch near one, the camera clips through it for a moment before snapping back to its original position. This issue is even more noticeable during crouch: it looks like the camera has a sort of “spring effect,” ignoring all collisions and continuing forward until I release the forward movement key.

Below is a video demonstrating the problem:

So far, I’ve tried increasing the radius of the Capsule Component, which partially solves the issue, but this is bulky and not optimal.
I’d like to know if there’s a method to prevent this problem or if I need to create a brand new first-person Character Blueprint from scratch.

Thank you in advance for your help.

Is DoCollisionTest checked on the spring arm component?

Also, this thread has some ideas on the topic if you haven’t seen it already Spring Arm Problem - Development / Programming & Scripting - Epic Developer Community Forums (unrealengine.com)

Hey there, I checked to see if DoCollisionTest was enabled (because I honestly didn’t remember) and it was.
I had already looked at the link you provided, but unfortunately it didn’t solve my problem: the mannequin mesh is invisible in my Character Blueprint since I don’t need it rendered so there is no risk for the character to clipping in itself, but I do need the head movement and animation dynamics from the Game Animation Sample.
I lowered the near clip plane to 1, but it still clips into walls and other props, so that doesn’t really fix the issue.

Hey bro did u solve the problem? I’m having the same issue with prone and crouch function. And my character is just capsule component. Spring arm collision doesn’t work.

If character mesh i s hidden, try attaching it 10cm behind the head or so (add a new camera socket to head bone on skele if need be), and lower the FoV a bit to zoom camera in if the offset is noticeable. Or since the problem seems to be run anim clipping head into wall, use a control rig to post process the anim bp, and have it essentially clamp the head’s x location and use a full body ik forward solver to fix the other bones. Look in third person template to see how they did the foot IK.

Or get a new run/jog animation that doesn’t lean so far forward that head escapes capsule.