Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Question Retargeting Animations with Generic Rigs

Discussion in 'Animation' started by petey, Jun 1, 2020.

  1. petey

    petey

    Joined:
    May 20, 2009
    Posts:
    1,732
    Hi there,

    I have a generic rigged character that I'm using throughout my game. I'd love to be able to reuse animation across rigs of different proportion but it seems that when you load animation onto the character, the proportions completely change to that of the source animation. I'd expected that the animation would look a little out of whack but I wasn't expecting the actual bone lengths to change.
    Is there any way to get this to work? My rig doesn't work well with the Humanoid system.
    I realise there are a bunch of threads on this subject but they are all years old. I'm asking out of desperation really, surely someone has had do do something like this before :(

    Thanks,
    Pete
     
    martygrof3708 likes this.
  2. Kybernetik

    Kybernetik

    Joined:
    Jan 3, 2013
    Posts:
    2,396
    I don't know of any tools that can do that. I think it might be possible to develop a retargeting system using the Animation Jobs system, but you'd be implementing the whole thing from scratch.
     
  3. dibdab

    dibdab

    Joined:
    Jul 5, 2011
    Posts:
    976
  4. petey

    petey

    Joined:
    May 20, 2009
    Posts:
    1,732
    Awesome thanks for that. I had no idea you could get to the curves like that. There are still a bunch of problems but this is a big push in the right direction for sure! :)
    Thanks!
     
    Z-Dom likes this.
  5. Z-Dom

    Z-Dom

    Joined:
    Feb 6, 2020
    Posts:
    2
    Whey,

    thanks a lot @dibdab
    We have encountered exactly the same issues with sharing animations between male & female characters, just tested your script and it works perfectly!
     
  6. SepM

    SepM

    Joined:
    Jun 23, 2014
    Posts:
    3
    You're a lifesaver! I was getting a little panicked when my animations got wacky and there weren't many solutions out there! Thank you!