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 How to access from Runtime Animation's Dopesheet values

Discussion in 'Animation' started by Ahab_, Nov 15, 2020.

  1. Ahab_

    Ahab_

    Joined:
    May 22, 2019
    Posts:
    22
    Hello.

    Is there any way to access the Dopesheet values of a specific animation through Runtime?

    I am talking about the info shown in the attached picture.

    dopesheet.PNG

    Would be really nice to find a way to modify it by a script instead of doing it always manually for each animation.

    Thanks!
     
  2. Kybernetik

    Kybernetik

    Joined:
    Jan 3, 2013
    Posts:
    2,340
    If you add custom curves to the animation, you can make a float parameter with the same name in your Animator Controller and Unity will automatically update it every frame with the value of that curve so you can get it from there.

    But I have no idea if that technique can be used for curves that are already controlling something.
     
  3. Ahab_

    Ahab_

    Joined:
    May 22, 2019
    Posts:
    22
    hI
    Thanks for your reply.

    What I try to achieve is to correct offset values for specific bones when I apply animations to specific characters. You know, sometimes limbs don't have the exact appropiate angle and such and is really bothering.

    Can be fixed manually but is such a waste of time.

    I made some google searches I found ideas similar to yours in old posts, but still, I couldn't came up with a straight solution.