RandomGFGoStop/Assets/Scripts/UI/Popup/MissionOpenPopup.cs

28 lines
612 B
C#
Raw Normal View History

2025-09-04 05:54:48 +00:00
using System.Collections;
using UnityEngine;
public class MissionOpenPopup : PopupBase
{
2025-09-16 03:19:51 +00:00
public static bool NeedBtn;
2025-09-04 05:54:48 +00:00
public GameObject go_btn;
public override void ShowPopup(int drawOrder)
{
base.ShowPopup(drawOrder);
GameManager.Sound.PlaySFX(ESFXType.Open_Popup);
StartCoroutine(Co_Off());
}
IEnumerator Co_Off()
{
go_btn.SetActive(false);
yield return new WaitForSeconds(2.5f);
2025-09-16 03:19:51 +00:00
if (NeedBtn) go_btn.SetActive(true);
else OnClick_OK();
2025-09-04 05:54:48 +00:00
}
public void OnClick_OK()
{
GameManager.UI.HideTopPopup();
}
}