备份CatanBuilding瘦身独立工程

This commit is contained in:
JSD\13999
2026-05-26 16:15:54 +08:00
commit 2d0e6a61b7
12001 changed files with 2431925 additions and 0 deletions

View File

@@ -0,0 +1,47 @@
using System;
using GameCore;
using UnityEngine;
public class FishingNoticePopupPanel : MonoBehaviour
{
public enum NoticeType
{
RECONNECTED,
UPDATE,
MAINTENANCE,
}
static FishingNoticePopupPanel _instance;
public FishingNoticePopupPanel Show(NoticeType type = NoticeType.RECONNECTED)
{
ShowInit();
_instance.transform.SetAsLastSibling();
_instance.ShowNotice(type);
return _instance;
}
private static async void ShowInit()
{
if (_instance == null)
{
GameObject loading = await UIManager.Instance.GetUIAsync(UITypes.FishingNoticePopupPanel);
if (loading != null)
{
_instance = loading.GetComponent<FishingNoticePopupPanel>();
}
}
}
public GameObject[] noticeList;
public Action OnOkButtonClick;
void ShowNotice(NoticeType type)
{
for (int i = 0; i < noticeList.Length; i++)
{
noticeList[i].SetActive(i == (int)type);
}
}
}