|
- using System;
- using CIG.Translation;
- using Tweening;
- using UnityEngine;
-
- public class TutorialPopupView : PopupBaseView
- {
- public void OnContinueClicked()
- {
- if (!base.PopupState.Closed)
- {
- ((TutorialPopupState)this.State).Continue();
- }
- }
-
- public override void OnBlackOverlayClicked()
- {
- this.OnContinueClicked();
- }
-
- public void UpdateInfo(ILocalizedString bodyText, ILocalizedString buttonText, bool showFlares)
- {
- this._flareTweener.gameObject.SetActive(showFlares);
- if (showFlares && !this._flareTweener.IsPlaying)
- {
- this._flareTweener.Play();
- }
- else if (!showFlares && this._flareTweener.IsPlaying)
- {
- this._flareTweener.Stop();
- }
- this._bodyLabel.LocalizedString = bodyText;
- this._buttonLabel.LocalizedString = buttonText;
- }
-
- [SerializeField]
- private LocalizedText _bodyLabel;
-
- [SerializeField]
- private LocalizedText _buttonLabel;
-
- [SerializeField]
- private Tweener _flareTweener;
- }
|