Esempio n. 1
0
 private void SetControlsActive(bool value)
 {
     control.visible = value;
     UnityDialogueUIControls.SetControlActive(label, value);
     UnityDialogueUIControls.SetControlActive(textField, value);
     UnityDialogueUIControls.SetControlActive(panel, value);
 }
Esempio n. 2
0
 /// <summary>
 /// Sets the controls active/inactive.
 /// </summary>
 /// <param name="value">If set to <c>true</c> value.</param>
 public override void SetActive(bool value)
 {
     UnityDialogueUIControls.SetControlActive(line, value);
     UnityDialogueUIControls.SetControlActive(portraitImage, value);
     UnityDialogueUIControls.SetControlActive(portraitName, value);
     UnityDialogueUIControls.SetControlActive(continueButton, value);
     UnityDialogueUIControls.SetControlActive(panel, value);
 }
 /// <summary>
 /// Starts the timer.
 /// </summary>
 /// <param name='timeout'>
 /// Timeout duration in seconds.
 /// </param>
 public override void StartTimer(float timeout)
 {
     if (timer != null)
     {
         if (timerEffect == null)
         {
             UnityDialogueUIControls.SetControlActive(timer, true);
             timerEffect = timer.GetComponent <TimerEffect>();
             UnityDialogueUIControls.SetControlActive(timer, false);
         }
         if (timerEffect != null)
         {
             timer.progress              = 1;
             timerEffect.duration        = timeout;
             timerEffect.TimeoutHandler -= OnTimeout;
             timerEffect.TimeoutHandler += OnTimeout;
             UnityDialogueUIControls.SetControlActive(timer, true);
         }
     }
 }
        /// <summary>
        /// Sets the controls active/inactive, except this method never activates the timer. If the
        /// UI's display settings specify a timeout, then the UI will call StartTimer() to manually
        /// activate the timer.
        /// </summary>
        /// <param name='value'>
        /// Value (<c>true</c> for active; otherwise inactive).
        /// </param>
        public override void SetActive(bool value)
        {
            subtitleReminder.SetActive(value && subtitleReminder.hasText);
            foreach (GUIButton button in buttons)
            {
                UnityDialogueUIControls.SetControlActive(button, value && button.visible);
            }
            UnityDialogueUIControls.SetControlActive(timer, false);
            UnityDialogueUIControls.SetControlActive(pcImage, value);
            UnityDialogueUIControls.SetControlActive(pcName, value);
            UnityDialogueUIControls.SetControlActive(panel, value);

            if (value == true)
            {
                if ((pcImage != null) && (pcPortraitTexture != null))
                {
                    pcImage.image = pcPortraitTexture;
                }
                if ((pcName != null) && (pcPortraitName != null))
                {
                    pcName.text = pcPortraitName;
                }
            }
        }
 public override void SetActive(bool value)
 {
     base.SetActive(value);
     UnityDialogueUIControls.SetControlActive(panel, value);
 }
 public override void ShowPanel()
 {
     UnityDialogueUIControls.SetControlActive(panel, true);
 }
Esempio n. 7
0
 /// <summary>
 /// Hides the continue button.
 /// </summary>
 public override void HideContinueButton()
 {
     UnityDialogueUIControls.SetControlActive(continueButton, false);
 }
Esempio n. 8
0
 /// <summary>
 /// Shows the continue button.
 /// </summary>
 public override void ShowContinueButton()
 {
     UnityDialogueUIControls.SetControlActive(continueButton, true);
 }