123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596 |
- using System;
- using System.Collections.Generic;
- using I2.Loc;
- public class FreeModeSelect : WfScreenChildren
- {
- public override void Awake()
- {
- this.RootPanel = UTY.GetChildObject(base.transform.parent.transform.parent.gameObject, "MenuSelect", false);
- this.free_mode_select_mgr_ = base.transform.parent.gameObject.GetComponent<SceneFreeModeSelectManager>();
- NDebug.AssertNull(this.free_mode_select_mgr_ != null);
- base.Awake();
- this.btn_dic_.Add("ストーリー", UTY.GetChildObject(base.root_obj, "Menu/FreeModeMenuButton/ストーリー", false).GetComponent<UIButton>());
- this.btn_dic_.Add("日常", UTY.GetChildObject(base.root_obj, "Menu/FreeModeMenuButton/日常", false).GetComponent<UIButton>());
- this.btn_dic_.Add("夜伽", UTY.GetChildObject(base.root_obj, "Menu/FreeModeMenuButton/夜伽", false).GetComponent<UIButton>());
- this.btn_dic_.Add("キャンセル", UTY.GetChildObject(base.root_obj, "Cancel", false).GetComponent<UIButton>());
- this.btn_dic_.Add("ライフモード", UTY.GetChildObject(base.root_obj, "Menu/FreeModeMenuButton/ライフモード", false).GetComponent<UIButton>());
- if (DailyMgr.IsLegacy)
- {
- this.btn_dic_.Add("VIP", UTY.GetChildObject(base.root_obj, "Menu/FreeModeMenuButton/VIP", false).GetComponent<UIButton>());
- }
- else
- {
- this.btn_dic_.Add("VIP", UTY.GetChildObject(base.root_obj, "Menu/FreeModeMenuButton/VIP_HEvent", false).GetComponent<UIButton>());
- }
- UILabel component = UTY.GetChildObject(base.root_obj, "Menu/ExplanatoryText/Value", false).GetComponent<UILabel>();
- Localize component2 = component.GetComponent<Localize>();
- component.text = "回想のジャンルを選択してください。";
- if (component2 != null)
- {
- component2.SetTerm("SceneFreeModeSelect/回想のジャンルを選択してください。");
- }
- foreach (KeyValuePair<string, UIButton> keyValuePair in this.btn_dic_)
- {
- EventDelegate eventDelegate = new EventDelegate(this, "OnClickEvent");
- EventDelegate.Parameter[] parameters = eventDelegate.parameters;
- parameters[0].value = keyValuePair.Key;
- EventDelegate.Add(keyValuePair.Value.onClick, eventDelegate);
- }
- UTY.GetChildObject(base.root_obj, "Menu/FreeModeMenuButton", false).GetComponent<UIGrid>().repositionNow = true;
- }
- protected override void OnCall()
- {
- }
- private void OnClickEvent(string type_name)
- {
- if (type_name != null)
- {
- if (!(type_name == "ストーリー"))
- {
- if (!(type_name == "日常"))
- {
- if (!(type_name == "VIP"))
- {
- if (!(type_name == "夜伽"))
- {
- if (!(type_name == "キャンセル"))
- {
- if (type_name == "ライフモード")
- {
- this.free_mode_select_mgr_.CallEmpireLifeMode();
- }
- }
- else
- {
- this.free_mode_select_mgr_.CallCharaSelect();
- }
- }
- else
- {
- this.free_mode_select_mgr_.CallYotogiMode();
- }
- }
- else
- {
- this.free_mode_select_mgr_.CallVipMode();
- }
- }
- else
- {
- this.free_mode_select_mgr_.CallEverydayMode();
- }
- }
- else
- {
- this.free_mode_select_mgr_.CallStoryMode();
- }
- }
- }
- private Dictionary<string, UIButton> btn_dic_ = new Dictionary<string, UIButton>();
- private SceneFreeModeSelectManager free_mode_select_mgr_;
- }
|