Esempio n. 1
0
 // Token: 0x06000DED RID: 3565 RVA: 0x0003E6DC File Offset: 0x0003C8DC
 private void UpdateLimbs()
 {
     if (!this.valid)
     {
         return;
     }
     for (int i = 0; i < this.limbPairs.Length; i++)
     {
         LimbMatcher.LimbPair limbPair        = this.limbPairs[i];
         Transform            targetTransform = limbPair.targetTransform;
         if (targetTransform && limbPair.originalTransform)
         {
             limbPair.originalTransform.position = targetTransform.position;
             limbPair.originalTransform.rotation = targetTransform.rotation;
             if (i < this.limbPairs.Length - 1)
             {
                 float num = Vector3.Magnitude(this.limbPairs[i + 1].targetTransform.position - targetTransform.position);
                 float originalLimbLength = limbPair.originalLimbLength;
                 if (this.scaleLimbs)
                 {
                     Vector3 localScale = limbPair.originalTransform.localScale;
                     localScale.y = num / originalLimbLength;
                     limbPair.originalTransform.localScale = localScale;
                 }
             }
         }
     }
 }
Esempio n. 2
0
 // Token: 0x06001171 RID: 4465 RVA: 0x00056ACC File Offset: 0x00054CCC
 public void SetChildLocator(ChildLocator childLocator)
 {
     for (int i = 0; i < this.limbPairs.Length; i++)
     {
         LimbMatcher.LimbPair limbPair        = this.limbPairs[i];
         Transform            targetTransform = childLocator.FindChild(limbPair.targetChildLimb);
         this.limbPairs[i].targetTransform = targetTransform;
     }
 }
Esempio n. 3
0
 // Token: 0x06000DEB RID: 3563 RVA: 0x0003E670 File Offset: 0x0003C870
 public void SetChildLocator(ChildLocator childLocator)
 {
     this.valid = true;
     for (int i = 0; i < this.limbPairs.Length; i++)
     {
         LimbMatcher.LimbPair limbPair  = this.limbPairs[i];
         Transform            transform = childLocator.FindChild(limbPair.targetChildLimb);
         if (!transform)
         {
             this.valid = false;
             return;
         }
         this.limbPairs[i].targetTransform = transform;
     }
 }