void initComb(long id) { if (id == 0) { return; } ItemNodeState selectMaterial = GameLibrary.Instance().ItemStateList[id]; if (selectMaterial.syn_condition.Length > 0) { // if(selec) if (!EquipDevelop.GetSingolton().equipIntensifyDlg.equipCompoundPanel.gameObject.activeSelf) { EquipDevelop.GetSingolton().equipIntensifyDlg.equipCompoundPanel.gameObject.SetActive(true); } // EquipDevelop.GetSingolton().equipIntensifyDlg.equipCompoundPanel.InitData(selectMaterial); EquipDevelop.GetSingolton().equipIntensifyDlg.SetIntersifyData(EquipDevelop.GetSingolton().checkIndex + 1, id); gameObject.SetActive(false); } else { //UIGoodsGetWayPanel.Instance.SetID(id); //if (UILevel.instance.GetLevelData()) //{ // Control.ShowGUI(GameLibrary.UIGoodsGetWayPanel); //} Control.ShowGUI(UIPanleID.UIGoodsGetWayPanel, EnumOpenUIType.DefaultUIOrSecond, false, id); //出处面板 drop_fb 掉落副本的列表 } }
/// <summary> /// 英雄装备材料合成 4016 /// </summary> /// <param name="packet"></param> /// <returns></returns> public bool GetHeroEComResultHandle(CReadPacket packet) { Debug.Log("Get Hero Equip Com result"); Dictionary <string, object> data = packet.data; int resolt = int.Parse(data["ret"].ToString()); if (resolt == 0) { if (EquipDevelop.GetSingolton() != null && EquipDevelop.GetSingolton().equipIntensifyDlg.equipCompoundPanel.gameObject.activeSelf) { EquipDevelop.GetSingolton().equipIntensifyDlg.equipCompoundPanel.InitData(EquipDevelop.GetSingolton().equipIntensifyDlg.equipCompoundPanel.selectMaterial); } //刷新背包数据 //if (null != EquipInfoPanel.instance) //{ // EquipInfoPanel.instance.HeroEComHandler(); //} //EquipCompoundPanel.instance.OpenMaterialCompountEff();//播放合成特效 } else { Debug.Log(string.Format("装备合成错误:{0}", data["desc"].ToString())); } return(true); }
protected override void ShowHandler() { if (EquipDevelop.GetSingolton().index + 1 < 6) { InitData(playerData.GetInstance().selectHeroDetail.equipSite[EquipDevelop.GetSingolton().index + 1]); } else { InitData(playerData.GetInstance().selectHeroDetail.equipSite[6]); } }
protected override void ShowHandler() { equipEff.gameObject.SetActive(false); if (EquipDevelop.GetSingolton().index + 1 < 6) { InitData(playerData.GetInstance().selectHeroDetail.equipSite[EquipDevelop.GetSingolton().index + 1]); } else { InitData(playerData.GetInstance().selectHeroDetail.equipSite[6]); } }
/// <summary> /// 点击选择英雄卡片 /// </summary> private void OnIconClick() { if (heroNode.hero_id == playerData.GetInstance().selectHeroDetail.id) { EquipDevelop.GetSingolton().HeroPanel.gameObject.SetActive(false); return; } else { ClientSendDataMgr.GetSingle().GetHeroSend().SendGetHeroInfo(heroNode.hero_id, C2SMessageType.ActiveWait); //获取英雄信息 playerData.GetInstance().isEquipDevelop = true; EquipDevelop.GetSingolton().HeroPanel.gameObject.SetActive(false); } }
private void OnFosterClick() { //打开装备培养界面 Debug.Log("打开装备培养界面"); HeroPosEmbattle.instance.HideModel(); EquipDevelop.GetSingolton().index = equipData.site - 1; //Control.ShowGUI(GameLibrary.EquipDevelop); Control.ShowGUI(UIPanleID.EquipDevelop, EnumOpenUIType.OpenNewCloseOld); UI_HeroDetail.instance.HeroID = 0; //Control.HideGUI(GameLibrary.UI_HeroDetail); //Control.HideGUI(GameLibrary.UIHeroList); //Control.HideGUI(UIPanleID.UIHeroList); //Hide(); Control.HideGUI(this.GetUIKey()); }
public void InitData(EquipData equipdata) { ed = equipdata; if (null == ed) { return; } level.text = ed.level + "级"; iconFram.spriteName = UISign_in.GetspriteName(ed.grade); ItemNodeState itemnode = GameLibrary.Instance().ItemStateList[ed.id]; if (null != itemnode) { icon.spriteName = itemnode.icon_name; if (1 == itemnode.types) { if (null != upGradeArrow) { upGradeArrow.enabled = isUpLv(); upGradeArrow.spriteName = GetArrowName(EquipDevelop.GetSingolton().table); } } } if (hintEffect == null) { hintEffect = transform.Find("UI_SS_JianTou_01"); } if (hintEffect != null) { hintEffect.gameObject.SetActive(false); if (EquipDevelop.GetSingolton().table == 1)// EquipIntensifyPanel.instance.IsShow() { hintEffect.gameObject.SetActive(IsItemConditon()); } else if (EquipDevelop.GetSingolton().table == 0) //(EquipStrengthePanel.instance.IsShow()) { if (IsStrengeOneLv(0) && IsStrengeOneLv(1)) { hintEffect.gameObject.SetActive(true); } else { hintEffect.gameObject.SetActive(false); } } } }
void ChechButton() { if (INS.syn_condition.Length > 0) { EquipDevelop.GetSingolton().equipIntensifyDlg.SetIntersifyData(EquipDevelop.GetSingolton().index + 1, INS.props_id); } else { //如果没有合成材料显示出处面板 //UIGoodsGetWayPanel.Instance.SetID(INS.props_id); //if (UILevel.instance.GetLevelData()) //{ // Control.ShowGUI(GameLibrary.UIGoodsGetWayPanel); //} Control.ShowGUI(UIPanleID.UIGoodsGetWayPanel, EnumOpenUIType.DefaultUIOrSecond, false, INS.props_id); } }
protected override void ShowHandler() { if (INS == null) { long equpid = playerData.GetInstance().selectHeroDetail.equipSite[EquipDevelop.GetSingolton().index + 1].id; INS = GameLibrary.Instance().ItemStateList[equpid]; } MaterialName.spriteName = INS.icon_name; MaterialIcon.spriteName = UISign_in.GetspriteName(INS.grade); if (int.Parse(INS.props_id.ToString().Substring(0, 3)) == 103) { debris.gameObject.SetActive(true); } else { debris.gameObject.SetActive(false); } if (int.Parse(INS.props_id.ToString().Substring(0, 3)) == 102) { HeroData hd = playerData.GetInstance().GetHeroDataByID(Globe.selectHero.hero_id); EquipData ed; hd.equipSite.TryGetValue(HeroAndEquipNodeData.site, out ed); ItemNodeState ins = GameLibrary.Instance().ItemStateList[ed.id + 1]; Debug.Log(localpos + " ===>" + ed.id); if (ins != null) { if (localpos < ins.syn_condition.Length / 2) { MaterialNum.text = playerData.GetInstance().GetItemCountById(ins.syn_condition[localpos, 0]) + "/" + ins.syn_condition[localpos, 1].ToString(); } else { Debug.Log(localpos + " ===>" + ed.id); } } } else { Debug.Log(INS.props_id); MaterialNum.text = playerData.GetInstance().GetItemCountById(GameLibrary.Instance().ItemStateList[HeroAndEquipNodeData.Instance().GetReplaceNums(INS.props_id.ToString())].syn_condition[localpos, 0]) + "/" + GameLibrary.Instance().ItemStateList[HeroAndEquipNodeData.Instance().GetReplaceNums(INS.props_id.ToString())].syn_condition[localpos, 1].ToString(); } }
void CheckMaterial0() { ItemNodeState checkeitem = GameLibrary.Instance().ItemStateList[selectMaterial.syn_condition[0, 0]]; if (checkeitem.syn_condition.Length > 0) { EquipDevelop.GetSingolton().equipIntensifyDlg.SetIntersifyData(EquipDevelop.GetSingolton().index + 1, checkeitem.props_id); } else { //如果没有合成材料显示出处面板 //UIGoodsGetWayPanel.Instance.SetID(selectMaterial.syn_condition[0, 0]); //if (UILevel.instance.GetLevelData()) //{ // Control.ShowGUI(GameLibrary.UIGoodsGetWayPanel); //} Control.ShowGUI(UIPanleID.UIGoodsGetWayPanel, EnumOpenUIType.DefaultUIOrSecond, false, selectMaterial.syn_condition[0, 0]); } }
void ChechIcon() { EquipDevelop.GetSingolton().index = ed.site - 1; EquipDevelop.GetSingolton().ChangeSelect(); }
public void InitGuide() { //Debug.Log("<color=#10DF11>InitGuide true</color>" + playerData.GetInstance().guideData.uId); if (playerData.GetInstance().guideData.uId != 0 && GameLibrary.UI_Major == Application.loadedLevelName) { switch (playerData.GetInstance().guideData.uId) { case 906: go = UITaskTracker.instance.GuideBut; GuideTarget(); //EffectButton.transform.localPosition = new Vector3(78, -24, 0); break; case 919: go = Control.GetComponent(919); GuideTarget(); break; case 1219: go = Control.GetComponent(1219); GuideTarget(); break; case 2319: go = Control.GetComponent(2319); GuideTarget(); break; case 2719: go = Control.GetComponent(2319); GuideTarget(); break; case 2919: go = Control.GetComponent(2919); GuideTarget(); break; case 3019: go = Control.GetComponent(3019); GuideTarget(); break; case 1092: go = Control.GetComponent(1092); GuideTarget(); GetPanel(); break; case 1204: go = Control.GetComponent(1204); GuideTarget(); GetPanel(); break; case 1331: go = Control.GetComponent(1331); GuideTarget(); GetPanel(); break; case 2471: go = Control.GetComponent(2471); GuideTarget(); GetPanel(); break; case 2871: go = Control.GetComponent(2871); GuideTarget(); GetPanel(); break; case 25110: go = Control.GetComponent(25110); GuideTarget(); GetPanel(); break; case 2697: //EffectButton.transform.parent = UIEmbattle.instance.HeroButton1.transform; //GuideManager.Single().ChangeObjectPosition(EffectButton); //GuideManager.Single().ChangeObjectScale(EffectButton); //EffectButton.GetComponent<RenderQueueModifier>().m_target = UIEmbattle.instance.HeroButton1.GetComponent<UIWidget>(); ////GetPanel(); //NextGuidePanel.Single().GuideDialogWin.GetComponent<RenderQueueModifier>().m_target = UIEmbattle.instance.HeroButton1.GetComponent<UIWidget>(); go = UIEmbattle.instance.HeroButton1; GuideTarget(); GetPanel(); break; case 3194: go = Control.GetComponent(3194); GuideTarget(); GetPanel(); break; case 3219: go = Control.GetComponent(3219); GuideTarget(); GetPanel(); break; case 33120: //EffectButton.transform.parent = EquipDevelop.GetSingolton().selectFram.gameObject.transform; //GuideManager.Single().ChangeObjectPosition(EffectButton); //GuideManager.Single().ChangeObjectScale(EffectButton); //EffectButton.GetComponent<RenderQueueModifier>().m_target = EquipDevelop.GetSingolton().selectFram.gameObject.GetComponent<UIWidget>(); go = EquipDevelop.GetSingolton().selectFram.gameObject; GuideTarget(); GetPanel(); break; case 35120: //EffectButton.transform.parent = EquipDevelop.GetSingolton().EvolveBtn.transform; //GuideManager.Single().ChangeObjectPosition(EffectButton); //GuideManager.Single().ChangeObjectScale(EffectButton); //EffectButton.GetComponent<RenderQueueModifier>().m_target = EquipDevelop.GetSingolton().EvolveBtn.GetComponent<UIWidget>(); //////GetPanel(); //NextGuidePanel.Single().GuideDialogWin.GetComponent<RenderQueueModifier>().m_target = EquipDevelop.GetSingolton().EvolveBtn.GetComponent<UIWidget>(); go = EquipDevelop.GetSingolton().EvolveBtnLabel; GuideTarget(); GetPanel(); break; case 36120: //EffectButton.transform.parent = EquipDevelop.GetSingolton().selectFram.gameObject.transform; //GuideManager.Single().ChangeObjectPosition(EffectButton); //GuideManager.Single().ChangeObjectScale(EffectButton); //EffectButton.GetComponent<RenderQueueModifier>().m_target = EquipDevelop.GetSingolton().selectFram.gameObject.GetComponent<UIWidget>(); //////GetPanel(); go = EquipDevelop.GetSingolton().selectFram.gameObject; GuideTarget(); GetPanel(); break; case 34120: go = Control.GetComponent(34120); GuideTarget(); GetPanel(); break; case 37120: go = Control.GetComponent(37120); GuideTarget(); GetPanel(); break; case 38120: go = Control.GetComponent(38120); GuideTarget(); GetPanel(); break; case 3938: go = Control.GetComponent(3938); GuideTarget(); GetPanel(); break; case 4031: go = Control.GetComponent(4031); GuideTarget(); GetPanel(); break; case 4119: go = Control.GetComponent(4119); GuideTarget(); GetPanel(); break; case 4397: go = Control.GetComponent(4397); GuideTarget(); GetPanel(); break; case 4297: //EffectButton.transform.parent = UIEmbattle.instance.HeroButton2.transform; //GuideManager.Single().ChangeObjectPosition(EffectButton); //GuideManager.Single().ChangeObjectScale(EffectButton); //EffectButton.GetComponent<RenderQueueModifier>().m_target = UIEmbattle.instance.HeroButton2.GetComponent<UIWidget>(); //NextGuidePanel.Single().GuideDialogWin.GetComponent<RenderQueueModifier>().m_target = UIEmbattle.instance.HeroButton2.GetComponent<UIWidget>(); //////GetPanel(); go = UIEmbattle.instance.HeroButton2; GuideTarget(); GetPanel(); break; case 4419: go = Control.GetComponent(1219); GuideTarget(); break; case 4531: go = Control.GetComponent(4531); GuideTarget(); GetPanel(); break; case 4638: go = Control.GetComponent(3938); GuideTarget(); GetPanel(); break; case 4731: go = Control.GetComponent(4031); GuideTarget(); GetPanel(); break; case 4897: if (UIEmbattle.instance != null) { go = UIEmbattle.instance.HeroButton2; } GuideTarget(); GetPanel(); break; case 4997: go = Control.GetComponent(4397); GuideTarget(); GetPanel(); break; default: break; } } }
//进化按钮事件 void EquipEvolve() { int needlv = (1 + playerData.GetInstance().selectHeroDetail.grade) * playerData.GetInstance().selectHeroDetail.grade / 2 + 1; if (ins.grade + 1 > needlv) { Control.ShowGUI(UIPanleID.UITooltips, EnumOpenUIType.DefaultUIOrSecond, false, "请提升英雄品质"); return; } //if (IsItemMaterialcondition) //{ // UITooltips.Instance.SetBlackerBottom_Text("进化材料不足,请查看"); // Control.ShowGUI(GameLibrary.UITooltips); // return; //} if (!Ismoney) { // UITooltips.Instance.SetBlackerBottom_Text("进化金币不足"); // Control.ShowGUI(GameLibrary.UITooltips); //金币不足时打开点金手面板 Control.ShowGUI(UIPanleID.UIGoldHand, EnumOpenUIType.DefaultUIOrSecond); return; } //发送通信协议 ClientSendDataMgr.GetSingle().GetHeroSend().SendHeroEMon(playerData.GetInstance().selectHeroDetail.id, EquipDevelop.GetSingolton().index + 1); }
void SetTabButton(int index, bool boo) { table = (byte)index; switch (index) { case 0: //IntensifyImg.spriteName = "yeqian-xuanzhong"; //EvolveImg.spriteName = "yeqian"; // Control.ShowGUI(GameLibrary.EquipStrengthePanel); equipStrenthDlg.gameObject.SetActive(true); equipStrenthDlg.InitData(playerData.GetInstance().selectHeroDetail.equipSite[EquipDevelop.GetSingolton().index + 1]); equipIntensifyDlg.gameObject.SetActive(false); ReshEquipItem(); strenthEffect.gameObject.SetActive(true); intensifyEffect.gameObject.SetActive(false); break; case 1: //IntensifyImg.spriteName = "yeqian"; //EvolveImg.spriteName = "yeqian-xuanzhong"; equipStrenthDlg.gameObject.SetActive(false); // Control.HideGUI(GameLibrary.EquipStrengthePanel); equipIntensifyDlg.gameObject.SetActive(true); equipIntensifyDlg.InitData(playerData.GetInstance().selectHeroDetail.equipSite[EquipDevelop.GetSingolton().index + 1]); ReshEquipItem(); strenthEffect.gameObject.SetActive(false); intensifyEffect.gameObject.SetActive(true); break; } }