少年修仙传客户端代码仓库
Client_PangDeRong
2018-10-12 fa4bb5491df435bcbb19aba25cd643911e62cf5f
4144 【前端】人物粉色品质防具装备的合成与拆解
3个文件已修改
2个文件已添加
76 ■■■■■ 已修改文件
Core/NetworkPackage/ClientPack/ClientToMapServer/CA3_Item/CA313_tagCMItemDecompound.cs 18 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/NetworkPackage/ClientPack/ClientToMapServer/CA3_Item/CA313_tagCMItemDecompound.cs.meta 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/KnapSack/Logic/ItemTipsModel.cs 35 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/KnapSack/Logic/PackSendQuestMgr.cs 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Utility/EnumHelper.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/NetworkPackage/ClientPack/ClientToMapServer/CA3_Item/CA313_tagCMItemDecompound.cs
New file
@@ -0,0 +1,18 @@
using UnityEngine;
using System.Collections;
// A3 13 物品拆解 #tagCMItemDecompound
public class CA313_tagCMItemDecompound : GameNetPackBasic {
    public byte Index;    // 拆解物品所在背包索引
    public CA313_tagCMItemDecompound () {
        combineCmd = (ushort)0x03FE;
        _cmd = (ushort)0xA313;
    }
    public override void WriteToBytes () {
        WriteBytes (Index, NetDataType.BYTE);
    }
}
Core/NetworkPackage/ClientPack/ClientToMapServer/CA3_Item/CA313_tagCMItemDecompound.cs.meta
New file
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 77eef483c79a1a244b31335edb236af7
timeCreated: 1539335657
licenseType: Pro
MonoImporter:
  serializedVersion: 2
  defaultReferences: []
  executionOrder: 0
  icon: {instanceID: 0}
  userData:
  assetBundleName:
  assetBundleVariant:
System/KnapSack/Logic/ItemTipsModel.cs
@@ -710,6 +710,41 @@
                attrData.SetTipsFuncBtn(ItemWinBtnType.sell, (ItemWinBtnType, ItemAttrData) => { PackSendQuestMgr.Instance.SendSellQuest(ItemWinBtnType.sell,attrData); });
            }
            List<int> dismantleReturnlist = attrData.GetUseDataModel((int)ItemUseDataKey.Def_IudetItemDecompound);
            if (dismantleReturnlist != null && dismantleReturnlist.Count > 0)
            {
                int needGridCnt = 0;
                for(int i = 0; i < dismantleReturnlist.Count; i++)
                {
                    if(i == 0)
                    {
                       if(dismantleReturnlist[i] != 0)
                        {
                            needGridCnt += 1;
                        }
                    }
                    else
                    {
                        if((i-1) % 3 == 0)
                        {
                            if (dismantleReturnlist[i] != 0)
                            {
                                needGridCnt += 1;
                            }
                        }
                    }
                }
                if(needGridCnt > playerPack.GetReaminGridCount(PackType.rptItem))
                {
                    SysNotifyMgr.Instance.ShowTip("BagFull102",attrData.itemConfig.ItemName,needGridCnt);
                }
                else
                {
                    attrData.SetTipsFuncBtn(ItemWinBtnType.dismantle, (ItemWinBtnType, ItemAttrData) => { PackSendQuestMgr.Instance.SendDismantleQuest(ItemWinBtnType.dismantle, attrData); });
                }
            }
            if (!isOverdue)
            {
                if(attrData.itemConfig.JumpComposeCondi != null && attrData.itemConfig.JumpComposeCondi.Length > 0)
System/KnapSack/Logic/PackSendQuestMgr.cs
@@ -1083,6 +1083,15 @@
        }
        #endregion
        #region 发送拆解请求
        public void SendDismantleQuest(ItemWinBtnType btnType, ItemAttrData attrData)
        {
            CA313_tagCMItemDecompound decompound = new CA313_tagCMItemDecompound();
            decompound.Index = (byte)attrData.index;
            GameNetSystem.Instance.SendInfo(decompound);
        }
        #endregion
        #region 发送续费请求 
        public void SendRenewalQuest(ItemWinBtnType btnType,int index)
        {
Utility/EnumHelper.cs
@@ -1487,6 +1487,7 @@
    Def_IudetSuiteLV = 30,  //套装等级
    Def_IudetDogzEquipPlus = 31,  // 神兽装备强化信息列表 [强化等级, 强化熟练度]
    Def_IudetHasOpenCnt = 32,  // 物品累积开启次数
    Def_IudetItemDecompound = 33,  //合成物品拆解返还物品列表 [装备ID,材料1ID,个数,是否绑定,材料2ID,个数,是否绑定,...]
    Def_IudetCreateItemLoginDay = 34,  //创建物品时的登录天数
    Def_IudetLastOpenItemLoginDay = 36,  //上一次开启物品时的登录天数
    Def_IudetRuneLV = 38,  // 符印等级
@@ -1507,6 +1508,7 @@
{
    makeUse, //使用
    putOn, //穿上
    dismantle, //拆解合成装备
    split, //拆分
    putAway,//上架
    inlay, //镶嵌