using System.Collections; using System.Collections.Generic; using Unity.VisualScripting; using UnityEngine; namespace Ether { public enum MenuSubFrameType { ClueFrame, MenuTipsFrame, BagFrame, MapFrame, FriendFrame, AchievementFrame, SettingFrame, } public class MenuFrame : MenuFrameBase { protected override void OnShow() { _ToggleGroupExMenu.OnValueChange.AddListener(OnToggleValueChanged); _ToggleGroupExMenu.SelectIndex = OpenFrameData.GetData("SelectIndex"); } private void OnToggleValueChanged(int selectIndex) { OpenFrameData openFrameData = new OpenFrameData(); openFrameData.SetParentFrameData(FrameData.FrameName, _TransSubFrameRoot); UIManager.Inst.OpenFrame(((MenuSubFrameType)selectIndex).ToString(), openFrameData); } } }