Beispiel #1
0
 public void SetIsLinkText(bool isLink)
 {
     if (isLink)
     {
         strikeLine_.gameObject.SetActive(isLink);
         Foreground = GetDesiredTextColor();
         strikeLine_.transform.localPosition = new Vector3(strikeLine_.transform.localPosition.x, -5, strikeLine_.transform.localPosition.z);
         strikeLine_.SetColor(GameContext.Config.ThemeColor);
         OnTextLengthChanged();
     }
     else if (BindedLine.IsDone == false && BindedLine.IsComment == false)
     {
         strikeLine_.gameObject.SetActive(isLink);
         Foreground = GetDesiredTextColor();
         strikeLine_.transform.localPosition = new Vector3(strikeLine_.transform.localPosition.x, 0, strikeLine_.transform.localPosition.z);
         strikeLine_.SetColor(GameContext.Config.StrikeColor);
     }
 }
Beispiel #2
0
 protected override void OnFocused()
 {
     if (isEditing_ == false)
     {
         isEditing_ = true;
         underLine_.gameObject.SetActive(true);
         underLine_.SetColor(Foreground);
         underLine_.Rate = 0.0f;
         AnimManager.AddAnim(underLine_, 1.0f, ParamType.GaugeRate, AnimType.Time, 0.15f);
         AnimManager.AddAnim(this, 0.4f, ParamType.TextAlphaColor, AnimType.Time, 0.15f);
     }
 }
    // Update is called once per frame
    void Update()
    {
        Prev.SetColor(ColorManager.MakeAlpha(Prev.color, (Mathf.Sin(Time.time * BlinkRate) + 1) / 2));
        Current.SetColor(Color.Lerp(currentColor_, nextColor_, (Mathf.Sin(Time.time * BlinkRate / 2) + 1) / 2 - 0.3f));

        if (TextCurrentGravity > (int)Gravity)
        {
            TextCurrentGravity -= 7;
            if (TextCurrentGravity <= (int)Gravity)
            {
                TextCurrentGravity = (int)Gravity;
            }

            Text.text = TextCurrentGravity.ToString();
        }
    }
Beispiel #4
0
 public void SetColor(Color color)
 {
     Line1.SetColor(color);
     Line2.SetColor(color);
 }