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

error CS1061

Discussion in 'Scripting' started by keepthachange, Oct 6, 2015.

  1. keepthachange

    keepthachange

    Joined:
    Oct 15, 2014
    Posts:
    87
    ScriptCSharp/AttackTriggerC.cs(228,103): error CS1061: Type `UnityEngine.Animator' does not contain a definition for `GetCurrentAnimatorClipInfo' and no extension method `GetCurrentAnimatorClipInfo' of type `UnityEngine.Animator' could be found (are you missing a using directive or an assembly reference?)


    Code (CSharp):
    1. GetComponent<PlayerMecanimAnimationC>().AttackAnimation(attackCombo[c].name);
    2.                     float clip = GetComponent<PlayerMecanimAnimationC>().animator.GetCurrentAnimatorClipInfo(0).Length;
    3.                     wait = clip - 0.3f;



    ScriptCSharp/AttackTriggerC.cs(296,103): error CS1061: Type `UnityEngine.Animator' does not contain a definition for `GetCurrentAnimatorClipInfo' and no extension method `GetCurrentAnimatorClipInfo' of type `UnityEngine.Animator' could be found (are you missing a using directive or an assembly reference?)






    Code (CSharp):
    1. GetComponent<PlayerMecanimAnimationC>().AttackAnimation(skill[skillID].skillAnimation.name);
    2.                     float clip = GetComponent<PlayerMecanimAnimationC>().animator.GetCurrentAnimatorClipInfo(0).Length;
    3.                     wait = clip - 0.3f;
     
    Last edited: Oct 6, 2015
  2. keepthachange

    keepthachange

    Joined:
    Oct 15, 2014
    Posts:
    87
    How can i get this to work with unity 4 pro.
    Any help would be grand mates.