public override void SetSelectInfo() { foreach (GameObject obj in GameObject.FindGameObjectsWithTag("HeroPartyButton")) { HeroPartyButton hero_party_button = obj.GetComponent <HeroPartyButton>(); if (hero_party_button.IsSelect()) { if (!select_id.Contains(hero_party_button.hero_party.id.ToString())) { select_id.Add(hero_party_button.hero_party.id.ToString()); hero_party_button.hero_party.is_selected = true; Debug.Log("Add selectid:" + hero_party_button.hero_party.id); } } } }
/// <summary> /// @param index /// </summary> public override void ClickButtonAction(int index) { if (!is_director_select) { HeroPartyButton button = Buttons[index].GetComponent <HeroPartyButton>(); button.ToggleSelect(); button.SetButtonText(); } else { UIManagerDirector party_manager_director = new UIManagerDirector(new HeroPartyManager()); HeroPartyButton button = Buttons[index].GetComponent <HeroPartyButton>(); button.ToggleSelect(); party_manager_director.GetSelectOne(); party_manager_director.SetSelectUI(); party_manager_director.SelectAllClear(); } SoundManager.instance.PlaySound("UI_Button_Click1"); }