Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Question Retargeting Animations with Generic Rigs

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

  1. petey

    petey

    Joined:
    May 20, 2009
    Posts:
    1,826
    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
     
    MintTree117 likes this.
  2. Kybernetik

    Kybernetik

    Joined:
    Jan 3, 2013
    Posts:
    2,583
    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,826
    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!