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 Animation Rigging Errors

Discussion in 'Animation Rigging' started by DanielRiches, Dec 9, 2022.

  1. DanielRiches

    DanielRiches

    Joined:
    Nov 23, 2019
    Posts:
    166
    I was in 2022.1.23f1 and all of a sudden my animation rigs are giving a bunch of errors and I have no idea why...

    All the references are done correctly, the avatar is fine with all references properly inserted in configuration...

    Does anyone know what causes this?

    upload_2022-12-9_2-18-43.png
    upload_2022-12-9_2-19-23.png
     

    Attached Files:

    Last edited: Dec 11, 2022
  2. DanielRiches

    DanielRiches

    Joined:
    Nov 23, 2019
    Posts:
    166
    I'm still stumped on this, the problem is I am not sure if it's something I have done wrong of if it's some bug with Unity, my Avatar is set up just fine, normal animations work fine, but the moment I activate my Rigs component is just says avatar invalid....

    upload_2022-12-10_19-1-4.png
     
  3. DanielRiches

    DanielRiches

    Joined:
    Nov 23, 2019
    Posts:
    166
    Heres a full rundown of my hierarchy, the deepest reference is to the left and right hand grips of the weapon...

    upload_2022-12-11_19-30-33.png
     
  4. akent99

    akent99

    Joined:
    Jan 14, 2018
    Posts:
    588
    No idea sorry (but I have had my share of pain and success with Animation Rigging). Did it work once now is failing? Or did it never work?

    In my case I upgraded another package (sequences) and things broke until they fixed a bug. So it might be worth trying the character in a test project with a different version of unity to see if you learn anything
     
  5. DanielRiches

    DanielRiches

    Joined:
    Nov 23, 2019
    Posts:
    166
    Im going to recreate the rig from scratch and see where exactly it breaks this time, still not exactly sure lol

    It used to work, but it suddenly stopped but I can't be sure if it was me restructuring things or some error with Unity.
     
    Last edited: Dec 12, 2022
  6. DanielRiches

    DanielRiches

    Joined:
    Nov 23, 2019
    Posts:
    166
    Ok, here's the rundown for anyone who seems to get these errors:

    The original animation rigging error appeared in 2021.23f but not straight away, once I added my third rig it started giving me these errors, so I upgraded to 2021.24f and it was still there. However, my animator was actually acting odd for a while, it used to spout Null Reference Exceptions inside my console (in 2021.23f) about transition states, despite all states being valid, and since it didn't overly break anything on runtime I just sort of ignored them.

    I think my player model's avatar had become corrupt somehow and this was leading to those errors, even upgrading to 2022.2 wouldn't work as the editor still claimed my avatar was invalid.

    I tried starting with a brand new model in the same project, did the rigging from scratch and it threw an error at step 1, I then started a brand new 2022.2 project and did the steps again, this time it all worked.

    In short, if you see these errors and you have ruled out any missing avatar references and any hierarchy organization issues, then your models avatar is likely bugged and you will probably need to start a new project.

    I'm planning to submit the project to hopefully have Unity investigate soon, as this is obviously not great if a studio has a lot of stuff in a project and it bugs in this way.

    Just to clarify, I now have everything working in a new project and have even added more rigs and functionality, and it all runs smoothly so far.
     
    B3Designs likes this.
  7. B3Designs

    B3Designs

    Joined:
    Apr 11, 2019
    Posts:
    6
    I am experiencing the exact same issues, with almost identical errors and warnings - though assets are very different.
    As with @DoomPriestK, everything was fine until I added the rigging (v1.1.1 in Unity 2021.3.11f1)
    Unfortunately, starting from scratch is not an option for me - I'm many months into a project that is over 36GB in size.
    One thing I did notice when looking at the screen grabs, is that everything starts with an error about a Transform that is not part of the HumanDescription. I have the same error (though my 'additional mesh' is the character's head, which is separate from the body mesh).
    Once I removed this extra Transform (and moved some stuff around a bit) rigging worked.
    This doesn't help me at all, as I'm now stuck with a character with no head (!), but it might help someone narrow down the issue with the avatar definitions.
     
  8. B3Designs

    B3Designs

    Joined:
    Apr 11, 2019
    Posts:
    6
    UPDATE: I've solved the issue - at least in my case.

    I moved the extra 'head' mesh up the hierarchy, still under the main character GO that contained the animator component, but outside of the main body / bones level. This threw another error about 'hair', so I moved that as well. Long story short, after I'd moved various armour sets, weapon rigs and other doohickeys away from the same level as the main character (the HumanDescription if you like) it worked without issue.

    Hope this helps anyone who finds this thread.
     
    DanielRiches likes this.
  9. Malghull

    Malghull

    Joined:
    Sep 28, 2017
    Posts:
    2
    Does anyone know if Unity is looking into this problem? I saw some threads that talked about this in 2021, I just got this error yesterday where I fixed everything up and it worked well, came back after a few hours and it just started throwing errors like what the other two people here have. Unfortunately none of the fixes others came up with worked for me :(
     
    Last edited: Feb 5, 2023