Home Technical Talk

Maya Animation to Unity?

Hello fellow Polycounters,

I'm working on an indie game project and running into problems importing animations that were created in Maya 2013 to Unity. I've searched google trying to find a solution and tried various techniques. However, I still am unable to import the animation to Unity. I've tried numerous variations of FBX export settings, but still have the same issue of transferring to Unity. Your insight is most appreciated!!

SCENE ASSETS
- MODEL
- BONES
- RIG (NURBS CONTROLLERS)

METHODS TRIED

-METHOD 1
1 - SAVED .MA & .MB FILES (MESH/BONES/RIG)
2 - IMPORTED INTO UNITY
3 - SETUP ANIMATION PROPERTIES IN IMPORT SETTINGS
4 - FAIL! NO ANIMATION INTACT


- METHOD 2
1 - BAKED IN ANIMATION TO MESH
2 - DELETED BONES & RIG
3 - CREATED GEOMETRY CACHE
4 - EXPORTED .FBX FILE
5 - NEW SCENE, RE-OPENED .FBX FILE IN MAYA (MESH ANIMATION INTACT)
6 - IMPORTED INTO UNITY
7 - SETUP ANIMATION SETTINGS/WRAPMODE IN IMPORT SETTINGS
GENERATION: STORED IN ROOT
ANIMATION WRAP MODE: LOOP
8 - FAIL!! NO ANIMATION :(

Need to convert Maya geometry cache file to .pc2 file and then import into Unity?

- METHOD 3
1 - BAKED ANIMATION TO BONES
2 - DELETED RIG (MADE SURE BONES ARE STILL OPERATIONAL)
3 - EXPORTED FBX (CHECKED THAT ANIMATION BAKE SETTINGS WERE SETUP)
4 - RE-IMPORTED INTO MAYA
5 - FAIL! (NO ANIMATION)

Replies

  • AnkylD
    Options
    Offline / Send Message
    I've struggled lately with maya to unity animations.
    You didn't mention which version of unity you are using and which animation system (mechanim or legacy).

    As i remember .fbx plugin for maya had versions which worked with unity and the ones which didn't. Maybe try to install earlier versions of this plugin.
  • AnkylD
    Options
    Offline / Send Message
    Accidentally double posted.
  • Warheart
    Options
    Offline / Send Message
    Warheart polycounter lvl 17
    Your third method should be the way to do it. From the information you gave I can't see why that wouldn't work.

    Couple of things to try:
    - With your method 3 (animation baked to joints) you're using "Export Selecion" then ensure "Input Connections" export option is checked.
    - Try instead of deleting your rig just select all your export skeleton joints and then do "Export Selection" with Bake Animation: on, Step: 1, Resample All: on, Input Connections: off.

    Other than that maybe posting your export settings in detail and posting the actual files you are exporting from (if you can) would help to work out what's going wrong.
  • R[]B[]T R|[]T
    Options
    Offline / Send Message
    Thank you guys for your input! I really appreciate the help. Sorry for the lack of information on the post. I will keep that in mind next time. I found out what the main issue was. It was a combination of Maya 2013 and model history that didn't get deleted during the rigging process. Anytime I tried to delete history I would lose my animation and the model would get detached from the rig. I found that if I use Maya 2010 and export the fbx, the animation transfers how it should. The animation is intact, however there is an extra mesh (thus indicating an issue with the model history).

    So for any of you having similar issues and have already tried using the standard FBX export to Unity process, try what AnkyID mentioned. Use a different version of maya.
  • R[]B[]T R|[]T
    Options
    Offline / Send Message
    Here are some links I found while researching the issue. Some of you might find this useful:


    Maya To Unity Animation Workflow [ Video Tutorial ]
    http://www.swinburne.edu.au/design/tutorials/P-unity/T-Character-animation-workflow-from-Maya-to-Unity3D/ID-265/

    Maya To Unity Tutorial
    http://forum.unity3d.com/threads/83159-Guide-Exporting-Complex-Rigs-from-Maya-to-Unity
  • AnkylD
    Options
    Offline / Send Message
    Just to clarify, i believe it's not necessary to install earilier verisons of maya. It should be possible to only install the plugin alone:

    http://usa.autodesk.com/adsk/servlet/pc/item?siteID=123112&id=10775920
  • Warheart
    Options
    Offline / Send Message
    Warheart polycounter lvl 17
    If it's only an issue when you have modelling history on the mesh have you tried "Delete Non-Deformer History"? If it is just a history issue and that doesn't fix it then I'd save the skin weights out, clean up the mesh and then re-bind and import the weights.

    Also, if you just need to export to an older FBX format then you don't need to install anything. You can just select it in the export options under Advanced Options > FBX File Format > Version.
  • littleclaude
    Options
    Offline / Send Message
    littleclaude quad damage
    Maya Animation to Unity is broken again, anyone know why its broken and how to fix it?

    I am using FBX, Maya 2014 and Unity 4.

    Inside Playmaker the ".anim" file will not show up? it just says "No Animations on Object"

    Oddly my old animations still work but only if the camera is looking at them?
  • passerby
    Options
    Offline / Send Message
    passerby polycounter lvl 12
    just broken for newer fbx?

    im still on 2012 and all i do is bake the animation on my bones to keyframes, than export fbx, and it works
  • littleclaude
    Options
    Offline / Send Message
    littleclaude quad damage
    These are my settings, are they okay?

    Unity1.jpg

    I have just tried

    FBX settings

    General Options - > check default file extension
    under include -> only smooth mesh is checked and reference container content
    under animation - > check animation
    under bake simulation -> check bake simulation
    under deformed models - > deformed models and skin is checked (although I don't believe you can use deformed models
    uncheck cameras and uncheck lights
    scale factor - > centimeters
    FBX file format -> ASCII
    FBX -> 2013
  • littleclaude
    Options
    Offline / Send Message
    littleclaude quad damage
    I have tried my old version of Maya, every single FBX year? rigged it in lots off different ways, exported my old working models from Maya that now don't work, opened a clean scene in Unity, not sure what else to try...

    http://docs.unity3d.com/Documentation/Manual/HOWTO-exportFBX.html
  • littleclaude
    Options
    Offline / Send Message
    littleclaude quad damage
    I think it may be a Playmaker issue? it just will not show up as having animation as an option?
    Working1.jpg

    Here is the FBX file, if anyone can test it I will buy you a pizza :)
    https://www.dropbox.com/s/f886uyj7eot6at6/Bronchi.fbx
  • littleclaude
    Options
    Offline / Send Message
    littleclaude quad damage
    Okay its all fixed now.

    I have chosen rig animation type "legacy" inside the inspector window for FBX export from maya 2014? not sure why this fixed it but it does. Note to self "do not update versions during a project no matter how many shiny bells and whistles."

    This is what it looks like if anyone else is stuck on the same issue. I have been animating in Unity today because of the FBX problems and it seems to save on memory? which is good to know, I guess it’s due to me keying only what I need, never mind.

    FBX settings from Maya 2014

    General Options - > check default file extension
    under include -> only smooth mesh is checked and reference container content
    under animation - > check animation
    under bake simulation -> check bake simulation
    under deformed models - > deformed models and skin is checked (although I don't believe you can use deformed models
    uncheck cameras and uncheck lights
    scale factor - > centimeters
    FBX file format -> ASCII
    FBX -> 2014

    Working1.jpg
Sign In or Register to comment.