CrayzyHayzy
CrayzyHayzy

Reputation: 11

Importing an exported .FBX from Blender to Unity object transform issue

Alrighty,

I have a dumpster model I have exported from Blender as an FBX. The transform, rotation and scales have all been applied in Blender. when importing into Unity and then adding to the scene, the model is elevated and rotated at an odd angle to the transform as per the image. The model has an armature for animating the lids an I have applied the location, rotation and scale on it as well. Any one else come across this or know of a fix?Thanks

Blender image

Incorrect dumpster transform and location image

Upvotes: 1

Views: 2119

Answers (3)

Programmer
Programmer

Reputation: 125275

The problem is that Blender uses the right-handed coordinate system which means the Z-axis is pointing upwards.

Unity uses the left-handed coordinate system which means the Y-axis is pointing upwards.

To fix this, set the X-axis rotation of the model to be -90. Press Ctrl+A and apply rotation. The X-axis rotation will look like it is now 0 after that. Set it to 90 again and export it to Unity.

This 3 minutes video should also help you do this if you are still confused.


If you still have problems, check your animation. Don't apply it to your model and see if it's the problem.

Upvotes: 3

David
David

Reputation: 16277

The simplest way to solve this would be as follows:

  1. Create a dummy game object (D)
  2. Transform/offset the position of D to make sure your object's position align with the dummy parent
  3. Put your game object as the child of the dummy game object D

You can then apply transform on D, rather than your own game object directly.

Upvotes: 0

user9596240
user9596240

Reputation:

Also as a side note, you can use blender files (.blend) directly with unity. So every time you modify them inside your project folder they change in unity as well.

Upvotes: 0

Related Questions