Exemplo n.º 1
0
    // Token: 0x06008697 RID: 34455 RVA: 0x0034AC84 File Offset: 0x00349084
    private void OnLateUpdate()
    {
        this.BlinkCtrl.CalcBlink();
        FBSBlinkControl fbsblinkControl = this.BlinkCtrl;

        if (this.BlinkCtrlEx != null)
        {
            fbsblinkControl = this.BlinkCtrlEx;
        }
        float blinkRate;

        if (fbsblinkControl.GetFixedFlags() == 0)
        {
            blinkRate = fbsblinkControl.GetOpenRate();
            if (this.EyeLookController)
            {
                float angleHRate = this.EyeLookController.eyeLookScript.GetAngleHRate(EYE_LR.EYE_L);
                float angleVRate = this.EyeLookController.eyeLookScript.GetAngleVRate();
                float min        = -Mathf.Max(this.EyeLookDownCorrect, this.EyeLookSideCorrect);
                float num        = 1f - this.EyeLookUpCorrect;
                if (num > this.EyesCtrl.OpenMax)
                {
                    num = this.EyesCtrl.OpenMax;
                }
                float num2;
                if (angleVRate > 0f)
                {
                    num2 = MathfEx.LerpAccel(0f, this.EyeLookUpCorrect, angleVRate);
                }
                else
                {
                    num2 = -MathfEx.LerpAccel(0f, this.EyeLookDownCorrect, -angleVRate);
                }
                if (angleHRate > 0f)
                {
                    num2 -= MathfEx.LerpAccel(0f, this.EyeLookSideCorrect, angleHRate);
                }
                else
                {
                    num2 -= MathfEx.LerpAccel(0f, this.EyeLookSideCorrect, -angleHRate);
                }
                num2  = Mathf.Clamp(num2, min, this.EyeLookUpCorrect);
                num2 *= 1f - (1f - this.EyesCtrl.OpenMax);
                this.EyesCtrl.SetCorrectOpenMax(num + num2);
            }
        }
        else
        {
            blinkRate = -1f;
        }
        this.EyebrowCtrl.CalcBlend(blinkRate);
        this.EyesCtrl.CalcBlend(blinkRate);
        this.MouthCtrl.CalcBlend(this.voiceValue);
    }
Exemplo n.º 2
0
    private void OnLateUpdate()
    {
        this.BlinkCtrl.CalcBlink();
        FBSBlinkControl fbsBlinkControl = this.BlinkCtrl;

        if (this.BlinkCtrlEx != null)
        {
            fbsBlinkControl = this.BlinkCtrlEx;
        }
        float blinkRate;

        if (fbsBlinkControl.GetFixedFlags() == (byte)0)
        {
            blinkRate = fbsBlinkControl.GetOpenRate();
            if (Object.op_Implicit((Object)this.EyeLookController))
            {
                float angleHrate = this.EyeLookController.eyeLookScript.GetAngleHRate(EYE_LR.EYE_L);
                float angleVrate = this.EyeLookController.eyeLookScript.GetAngleVRate();
                float num1       = -Mathf.Max(this.EyeLookDownCorrect, this.EyeLookSideCorrect);
                float num2       = 1f - this.EyeLookUpCorrect;
                if ((double)num2 > (double)this.EyesCtrl.OpenMax)
                {
                    num2 = this.EyesCtrl.OpenMax;
                }
                float num3 = (double)angleVrate <= 0.0 ? -MathfEx.LerpAccel(0.0f, this.EyeLookDownCorrect, -angleVrate) : MathfEx.LerpAccel(0.0f, this.EyeLookUpCorrect, angleVrate);
                float num4 = Mathf.Clamp((double)angleHrate <= 0.0 ? num3 - MathfEx.LerpAccel(0.0f, this.EyeLookSideCorrect, -angleHrate) : num3 - MathfEx.LerpAccel(0.0f, this.EyeLookSideCorrect, angleHrate), num1, this.EyeLookUpCorrect) * (float)(1.0 - (1.0 - (double)this.EyesCtrl.OpenMax));
                this.EyesCtrl.SetCorrectOpenMax(num2 + num4);
            }
        }
        else
        {
            blinkRate = -1f;
        }
        this.EyebrowCtrl.CalcBlend(blinkRate);
        this.EyesCtrl.CalcBlend(blinkRate);
        this.MouthCtrl.CalcBlend(this.voiceValue);
    }
Exemplo n.º 3
0
 // Token: 0x06008695 RID: 34453 RVA: 0x0034AC44 File Offset: 0x00349044
 public void SetBlinkControlEx(FBSBlinkControl ctrl)
 {
     BlinkCtrlEx = ctrl;
 }