Setting pivot point for door animation

Hey there

I’ve had huge problems with all of my doors. I could never set the pivot point as I wanted to in Blender, it just resets if it’s being imported in UE4. The problem is that the animation of a door doesn’t work properly if the pivot point is for example in the middle of the door. It should be at one of the lower edges of the door of course, so that the rotation looks as it should. In my case, the pivot point is on the wrong side and the door therefore rotates in the wrong direction…

I have tried to animate the door with the SetActorRotation function and with Matinee, both have the same result, because the pivot point is on the wrong side. Even if I set it in the level it takes the origin pivot point for the animation. What can I do?

Thank you for any help

I think there isn’t a way to handle the pivot point problem from within the editor, at least not that I have heard of.

I imagine the solution to be one of the following: offset the door in blender so that the centre of the scene is where you want the pivot of the door to be, or make the door skeletal, animate it and import into UE with the animations ready. No idea how that would work in blender though as I’m using not blender.

Also, and this is what I would go after as the core of the problem, why does the pivot resets upon import? It seems to me that this is the single, universal problem you have, does it happen to other objects as well, or just doors :)?

Is the object at 0,0,0 xyz upon export from blender in the scene? Again I’ve barely touched on blender and that was before the big update, but I believe its the same in all 3d editing soft. If you don’t centre the object ( so its pivot is at the centre of the whole everything) before export, the pivot will slide upon import into UE.

Also in max and maya e.g. we have the option to reset the xform which effectively removes all translations and makes current rotation scale and position native, or initial or whatever the word for it actually is. If you could find something alike in blender it would make sure that all problems which have to do with previous alterations to the object are not at play in causing the problem, might effectively get rid of it too.

Thank you for your answer. Yeah, this problem happens with every object, not just doors… I also have 3ds but I’m more known to blender. But all the documentations about pivot points didn’t help to solve the problem. Is it really so easy with Max?

I don’t use Blender myself, however when I’m exporting from Maya the pivot in UE4 tends to be 0,0,0 in Maya. So the dead center of the grid is where the corner of the door should be.

Alternatively inside of UE4 you could make a blueprint and give it a SceneComponent as a root, then add the StaticMeshComponent under the SceneComponent, and move the corner of the StaticMeshComponent door so it sits on the SceneComponent. That way the SceneComponent will rotate and be aligned with the corner of the door, rotating it along with it.

When your in blender

Make sure that your in Object mode, and then set the 3D cursor to Center (Shift - S for popup)…

Then adjust the mesh to the where you wish the pivot to be in relation to the 3D cursor. So if you want it on the left side (assuming your looking at the front face of the door), set the left side to be on the 3D cursor.

When you have the object positioned, then click on Set Origin (it’s over on the left side, for a generic install of 2.77), and choose, Set Origin to 3D Cursor.

Now when you do the FBX export, be sure to set forward Axis to X and the Z axis for up.

That should do it for you, and if the X axis comes in inverted, just reexport and set the forward axis to -X (negative X), and do a reimport, and you should be good to go.

So you can basically set the pivot point (or origin) to any place you wish.

Hope this helps.

Inc.

Thank you very much! That’s what I wanted. It seems I had this problem because of the export settings you mentioned.

One way to permanently change the pivot point is to create a blueprint and align your Actor relative to origin. The origin will be the pivot of resulting blueprint.

Thanks, but this question is already answered and the solution worked good for me

Hi,

There are many users facing the same problem but I think there is a solution for this problem within the editor itself.

There is an option in import FBX options under mesh ’ Transform Vertex to Abs…’, un-check this and your mesh’s pivot will be at its position.

try this, I hope this will help.

Even if that would be true, the pivot point would have to be placed before, because it is at a wrong position and that would not change anything.

Also, the answer from jayice is working very well. And I also managed to do that in 3dsMax.