示例#1
0
 private void Update()
 {
     if (m_checkTextboxFinished)
     {
         if (m_textboxToCheckFinished == null || m_textboxToCheckFinished.IsFinished())
         {
             RHManager.SetPause(false);
         }
     }
 }
示例#2
0
    public void AddLine(string s, Color c, int fontSize, bool checkTextboxFinished = false)
    {
        GameObject      go   = Instantiate(TextPrefab, Content);
        TextMeshProUGUI t    = go.GetComponentInChildren <TextMeshProUGUI>();
        Textbox         tbox = go.GetComponent <Textbox>();

        tbox.setText(s);
        t.color    = c;
        t.alpha    = 1.0f;
        t.fontSize = fontSize;
        Vector2 oldSize = Content.sizeDelta;

        Content.sizeDelta  = new Vector2(oldSize.x, oldSize.y + SIZE_OF_TEXT);
        ScrollSlider.value = 0.0f;
        if (checkTextboxFinished)
        {
            RHManager.SetPause(true);
            m_checkTextboxFinished   = true;
            m_textboxToCheckFinished = tbox;
        }
    }
示例#3
0
 private void processSlowInput()
 {
     if (!m_canSlow)
     {
         return;
     }
     if (Input.GetKeyDown("space"))
     {
         if (ScaledTime.GetScale(true) == 0.0f)
         {
             RHManager.SetPause(false);
         }
         else if (ScaledTime.GetScale(true) == 1.0f)
         {
             RHManager.SetSlowTextActive(true);
             ScaledTime.SetScale(0.5f, true);
         }
         else
         {
             RHManager.SetSlowTextActive(false);
             ScaledTime.SetScale(1.0f, true);
         }
     }
 }