public void OnSelectSkillButton(UnitEvolveContext context) { SoundUtil.PlaySE(SEID.SE_MENU_OK); SkillDialog.Show(context.charaMaster); }
private void setupEvol() { if (m_bEvolve) { m_EvolveList.Clear(); m_UnitEvolvePanel.EvolveList.Clear(); AndroidBackKeyManager.Instance.DisableBackKey(); new SerialProcess().Add( (System.Action next) => { //最初の進化先 int nextUnitId = (int)m_UnitId; MasterDataParamChara _masterAfter = m_MainUnitMaster; bool nameView = false; //進化先がなくなるまで追加処理 do { MasterDataParamCharaEvol _evolAfter = MasterDataUtil.GetCharaEvolParamFromCharaID((uint)nextUnitId); EvolveInfo evolveInfo = new EvolveInfo(); evolveInfo.charaMaster = _masterAfter; evolveInfo.evolveMaster = _evolAfter; evolveInfo.charaTexture = null; evolveInfo.nameView = nameView; m_EvolveList.Add(evolveInfo); nameView = true; nextUnitId = -1; if (_evolAfter != null) { _masterAfter = MasterFinder <MasterDataParamChara> .Instance.Find((int)_evolAfter.unit_id_after); if (_masterAfter != null) { nextUnitId = (int)_evolAfter.unit_id_after; } } //同一キャラがすでにリストに登録されていたら検索をやめる if (nextUnitId != -1 && checkEvolveCharaID((uint)nextUnitId) == false) { nextUnitId = -1; } } while (nextUnitId != -1); //ローディング表示開始 LoadingManager.Instance.RequestLoadingStart(LOADING_TYPE.GUARD); next(); }) .Add((System.Action next) => { AssetBundlerMultiplier multi = AssetBundlerMultiplier.Create(); for (int i = 0; i < m_EvolveList.Count; i++) { int no = i; AssetBundler assetBundler = AssetBundler.Create() .SetAsUnitTexture(m_EvolveList[i].charaMaster.fix_id, (o) => { m_EvolveList[no].charaTexture = o.GetTexture2D(TextureWrapMode.Clamp); }); multi.Add(assetBundler); } multi.Load( () =>//Success { next(); }, () =>//Error { next(); }); }) .Add((System.Action next) => { for (int i = 0; i < m_EvolveList.Count; i++) { UnitEvolveContext evolveContext = new UnitEvolveContext(); evolveContext.setup(m_EvolveList[i].charaMaster, m_EvolveList[i].evolveMaster, m_EvolveList[i].charaTexture, m_EvolveList[i].nameView); evolveContext.DidSelectItem = OnSelectSkillButton; m_UnitEvolvePanel.EvolveList.Add(evolveContext); } //ローディング表示終了 LoadingManager.Instance.RequestLoadingFinish(LOADING_TYPE.GUARD); AndroidBackKeyManager.Instance.EnableBackKey(); m_LastUpdateCount = UPDATE_LAYOUT_COUNT; next(); }) .Flush(); } m_Setup[(int)ToggleType.Evolve] = true; }