Exemplo n.º 1
0
 void UpdateLight()
 {
     Light.spotAngle = Mathf.Lerp(15, 45, LerpHelper.CurveToOneFastSlow(LivingEntityController.HealthFraction, 2));
     Light.intensity = Mathf.Lerp(1, 5, LerpHelper.CurveToOneFastSlow(LivingEntityController.HealthFraction, 2));
 }
Exemplo n.º 2
0
    void UpdateMoveSpeed()
    {
        float exhaustionBonus = Mathf.Lerp(ExhaustionMinimumBonus, 1f, LerpHelper.CurveToOneFastSlow(PlayerStatusController.EnergyFraction, 2));

        CurrentSpeed = BaseSpeed * exhaustionBonus * RunSpeedPercentBonus * PlayerStatusController.AgeRelatedDecay;
    }
 private void Update()
 {
     Text.color = Color.Lerp(StartingColor, TargetFadeColor, LerpHelper.Reverse(LerpHelper.CurveToOneFastSlow(Mathf.PingPong(Time.time / PulseDuration, 1), 2)));
 }