This commit is contained in:
kridoo
2026-01-15 17:47:25 +08:00
parent 0de84d7662
commit ed06047911
15 changed files with 28953 additions and 753 deletions

View File

@@ -22,65 +22,105 @@ public class UIPanelControll : MonoSingleton<UIPanelControll>
int nowIndex = 0; //<2F><>ǰ<EFBFBD>±<EFBFBD>
//<2F>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
bool isSpecialVersion = true;
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E6B1BE><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾ<EFBFBD><CABE><EFBFBD><EFBFBD>
float specialTimer = 0f;
float specialWaitTime = 3f;
int specialIndex = 0; //<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾ<EFBFBD><CABE><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 0-3
void Start()
{
GlobalEventMgr.Listen<int>(GameEvent.EventShowUI, GameDataManage_EventShowUI);
GlobalEventMgr.Listen(GameEvent.EventShowUI, GameDataManage_EventShowUIBeforeLongbiao);
}
private void Update()
{
if (isRun)
if (isSpecialVersion)
{
runTime += Time.deltaTime;
if (runTime >= waitTime)
//ÿ<><C3BF>3<EFBFBD><33><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾ<EFBFBD><CABE>ListUiImg[0]<5D><>ListUiImg[1]<5D><>ListUiImg[2]<5D><>ListUiImg[3]
specialTimer += Time.deltaTime;
if (specialTimer >= specialWaitTime)
{
isRun = false;
runTime = 0;
ListUiImg[nowIndex].gameObject.SetActive(false);
if (nowIndex==0)
specialTimer = 0f;
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>һ<EFBFBD><D2BB>
ListUiImg[specialIndex].gameObject.SetActive(false);
//<2F>л<EFBFBD><D0BB><EFBFBD><EFBFBD><EFBFBD>һ<EFBFBD><D2BB>
specialIndex = (specialIndex + 1) % 4;
//<2F><>ʾ<EFBFBD><CABE>ǰ
ListUiImg[specialIndex].gameObject.SetActive(true);
}
}
else
{
if (isRun)
{
runTime += Time.deltaTime;
if (runTime >= waitTime)
{
isRun = false;
runTime = 0;
ListUiImg[nowIndex].gameObject.SetActive(false);
if (nowIndex == 0)
{
}
}
}
if (isRun2)
{
runTime += Time.deltaTime;
if (runTime >= waitTime2)
{
isRun2 = false;
isRun = true;
runTime = 0;
ListUiImg[0].gameObject.SetActive(true);
ListUiImg[8].gameObject.SetActive(false);
GlobalEventMgr.Dispatch(GameEvent.EventPlayTimeline);
}
}
}
if (isRun2)
{
runTime += Time.deltaTime;
if (runTime >= waitTime2)
{
isRun2 = false;
isRun = true;
runTime = 0;
ListUiImg[0].gameObject.SetActive(true);
ListUiImg[8].gameObject.SetActive(false);
GlobalEventMgr.Dispatch(GameEvent.EventPlayTimeline);
}
}
}
void GameDataManage_EventShowUIBeforeLongbiao()
{
}
void GameDataManage_EventShowUI(int index)
{
if (index == 0|| index == 7)
if (isSpecialVersion)
{
nowIndex = index;
if (index == 0)
ListUiImg[8].gameObject.SetActive(true);
}
else
{
if (index == 0 || index == 7)
{
isRun2 = true;
ListUiImg[8].gameObject.SetActive(true);
}
else
{
ListUiImg[nowIndex].gameObject.SetActive(true);
}
if (index != 7&&index!=0)
isRun = true;
else
{
if (index == 7)
nowIndex = index;
if (index == 0)
{
waitTime = 5;
isRun2 = true;
ListUiImg[8].gameObject.SetActive(true);
}
else
{
ListUiImg[nowIndex].gameObject.SetActive(true);
}
if (index != 7 && index != 0)
isRun = true;
else
{
if (index == 7)
{
waitTime = 5;
isRun = true;
}
}
}
}