public void SendAnim(ProcAnimation anim)
 {
     if (!hasAnim)
     {
         currentAnimation = anim;
         anim.Init();
         hasAnim = true;
         if (anim.startFromPos == false)
         {
             foreach (AnimSegment segment in anim.animSegs)
             {
                 foreach (AnimSegment oldSegment in lastAnim.animSegs)
                 {
                     if (segment.animType == oldSegment.animType)
                     {
                         segment.procAnimation.SetAnimSegment(segment, GetEnd(oldSegment));
                         continue;
                     }
                 }
             }
         }
         SendAnimSeg(anim.animSegs);
     }
     else
     {
         Debug.LogError("ALREADY HAS ANIMATION");
     }
 }
 private void Start()
 {
     defaultAnim.Init();
     lastAnim         = defaultAnim;
     currentAnimation = defaultAnim;
     SendAnim(idleAnim);
 }