Collision Mesh not aligning with object.

Hi all,

im fairly new to unreal and coding in general. I have the following Problem: i created a rotating obstacle in my level. When placing it everything looks fine and even starting the game looks fine but i noticed that the collisions feel weird. After checking i saw that the collision mesh did not align with the object itself even though the viewport looks perfectly fine.

Lit view:

Collision View:

Viewport:

What am i doing wrong?

Is each one a blueprint? How are you rotating them?

it’s a blueprint child class derived from a cpp parent. the obstacles itself are just instances of the mentioned blueprint.

the code for rotation is basically just the “AddActorLocalRotation” function and keep in mind that the object is rotating properly. i just can’t explain why the object and the collision mesh won’t line up.

I don’t get how the collision is separate… :slight_smile:

It’s just a mesh, right? ( or did you make a collisin volume in the BP? )

Almost a year later i got back to coding a little bit and just wanted to update this in case anyone in the future is facing the same issue though i think this will not happen on a regular.
The issue was that the default cube asset from a ue5 learning project had a collision offset defined which had no effect as long as the object remained a cube. after changing it to a cuboid shape it did not align anymore. after removing the offset everything worked perfectly fine.

Welcome to the Unreal Engine forums @TheAddi. :slight_smile:

This topic has been moved from Tutorial & Course Discussions to Programming & Scripting. If you would prefer a different category, feel free to @ me and I’ll move your thread once more.

Thanks and happy developing! :smiley:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.