Search Unity

Sharing animation files across multiple different meshes

Discussion in 'Editor & General Support' started by jasonnorgaar, Apr 4, 2011.

  1. jasonnorgaar

    jasonnorgaar

    Joined:
    Jan 24, 2011
    Posts:
    16
    Hi I have been doing some testing of getting a single set of animations to play across different meshes that are all skinned to the same skeleton. My initial testing of the assets fails at the simplest level of just bringing the mesh in and dragging the animation on top of it.

    The mesh is not named the same as the the animation, I know unity follows has naming convention used for animations that expects the mesh and animation name to be the same. Following the "@" convention will not work for what we are developing since we need to have multiple mesh components in separate files. The test animation files I have created contain only the animated skeletons and the model files a skeleton in t-pose with a skinned mesh.

    We will store our source files outside of the unity project to avoid the auto exporting thing Unity does. Our files need to work only as straight exported fbx files. I am sort of at a loss here because I am positive the assets are identical with the exception of the mesh.

    I have attached a couple of the test files I have created. Any help would be a greatly appreciated.
    Attached Files
     

    Attached Files:

  2. jasonnorgaar

    jasonnorgaar

    Joined:
    Jan 24, 2011
    Posts:
    16
    Please anyone out there have an idea of what the issue is with the assets?
     
  3. jasonnorgaar

    jasonnorgaar

    Joined:
    Jan 24, 2011
    Posts:
    16
    Ok I think we have found the issue that is going on, but cannot figure out why it is happening. When I export the file that contains a mesh to fbx it retains the master node at the top of my skeleton hierarchy. But when I export the animated skeleton only, the master node doesn't show up unity, so it is seeing the hierarchies as different. They are not in fact different thought because if I import the fbx into Max the hierarchy is correct. Ideas anyone??
     
  4. jasonnorgaar

    jasonnorgaar

    Joined:
    Jan 24, 2011
    Posts:
    16
    Ok I found that if I place a null node in the skeleton only files and export them unity will then retain the master node at the top of the hierarchy. Then the animation files will work. This will be a working solution, maybe anyone who runs into this issue will find this thread useful.
     
  5. Sophie

    Sophie

    Joined:
    Feb 21, 2011
    Posts:
    2
    Are you using maya?
    If yes, you need to reference your models in a new scenes before exporting the TStand and make sure they all have the same namespace as the animation files. Back in unity make a new prefab with their TStand and they should be able to play the animation.
     
  6. jasonnorgaar

    jasonnorgaar

    Joined:
    Jan 24, 2011
    Posts:
    16
    Hi Sophie, I am using Max. Putting a dummy (null helper) node inside the scene, not connected to the hierarchy solved problem. Not sure why Unity strips out the master node unless the dummy node is there, but in any case it solves the problem. Thanks for the reply :)