30 lines
967 B
C#
30 lines
967 B
C#
using System;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using TMPro;
|
|
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
|
|
public class UI_MainTitlePanel : BasePanel
|
|
{
|
|
internal void Init()
|
|
{
|
|
var systemInfo = GameManager.DataMgr.GetSystemInfo(GameManager.ProcessMgr.id);
|
|
switch ( GameManager.RunModelMgr.ModeType)
|
|
{
|
|
case E_ModeType.Study:
|
|
GetControl<TextMeshProUGUI>("modelText (TMP)").text = "学习模式";
|
|
break;
|
|
case E_ModeType.Practice:
|
|
GetControl<TextMeshProUGUI>("modelText (TMP)").text = "练习模式";
|
|
break;
|
|
case E_ModeType.Exam:
|
|
GetControl<TextMeshProUGUI>("modelText (TMP)").text = "考试模式";
|
|
break;
|
|
}
|
|
|
|
|
|
GetControl<Image>("TopBgImg").sprite =
|
|
GameManager.ResourcesMgr.Load<Sprite>(Const.UI_MainTitlePanel + systemInfo.titleName);
|
|
}
|
|
} |