Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Change Model but save animations

Discussion in 'Animation' started by alarm656, May 18, 2014.

  1. alarm656

    alarm656

    Joined:
    Jul 6, 2013
    Posts:
    111
    Hello, I'm sorry if this question was posted before. I have a Arm/hand attached weapon with animations. I bought it from the asset store. I also bought weapons pack there are several types of weapons but they has no animations. Is it possible in unity to change attached weapon model to the models from pack and save animations from attached model? Just replace 3D weapon model and keep animations from replaced weapon:p? if yes please help me, give me a tips how to do it. Thanks thanks thanks:p
     
  2. alarm656

    alarm656

    Joined:
    Jul 6, 2013
    Posts:
    111
    Anyone please. Anyone has such as experience?
     
  3. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,670
    The answer is probably not, sorry. The skeleton (bone hierarchy) of the model must exactly match the skeleton used in the animation. Mecanim can retarget animations on Humanoid rigs -- that is, translate the motion from one skeleton definition to a different skeleton definition -- but since you only have a first-person arm/hand, it's not going to be a Humanoid rig.

    That said, if only the arms move, and not the weapon itself, then you can probably replace the old weapon model with a new model.
     
  4. alarm656

    alarm656

    Joined:
    Jul 6, 2013
    Posts:
    111
    Thank you. I think that first of all I have to properly attach all the weapons from the pack to the hand. Than make animation clips for Arm/Hand and for each weapon via Animation Window. By moving, rotating by the XYZ. Am I right?
     
  5. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,670
    Yes. I recently started using Skele. If it's in your budget, it's a great tool to use for this. It makes it very easy to create animation clips using Inverse Kinematics (IK). If you want to animate gun recoil, just drag the gun back. Skele will automatically rotate all the joints in the wrist, elbow, shoulder, etc. properly to accommodate the motion.
     
  6. alarm656

    alarm656

    Joined:
    Jul 6, 2013
    Posts:
    111
    Thank you TonyLi you're awesome:D. This is a cool Plugin.
     
  7. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,670
    Happy to help!