Example #1
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        m_data = new Dictionary <int, TD_SkillAI>();

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }

        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TD_SkillAI item;

        for (int i = 0; i < xmlNodeListLength; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item              = new TD_SkillAI();
            item.ID           = node.GetIntValue("ID");
            item.showFlag     = (Skill_ShowFlag)node.GetIntValue("showFlag");
            item.rangType     = (Skill_RangeType)node.GetIntValue("rangType");
            item.name         = node.GetStringValue("name");
            item.shootSkillID = node.GetIntValue("shootSkillID");
            item.trail        = node.GetStringValue("trail");
            item.passTrail    = node.GetStringValue("passTrail");
            item.eff          = node.GetStringValue("eff");
            item.effIcon      = node.GetStringValue("effIcon");
            item.useStep      = node.GetStringValue("useStep");
            item.actionType   = (Skill_ActionType)node.GetIntValue("actionType");
            item.keepRound    = node.GetIntValue("keepRound");
            item.effFun       = node.GetStringValue("effFun");

            m_data[item.ID] = item;
        }

        asset = null;

        if (null != m_callBack)
        {
            m_callBack();
            m_callBack = null;
        }

        base.onloaded(data);
    }
Example #2
0
    public static void CompleteCallback(AssetBundles.NormalRes data)
    {
        string asset = (data as AssetBundles.TxtRes).m_txt;

        if (asset == string.Empty)
        {
            return;
        }
        if (mNameStringDict.Count == 0)
        {
            ReadString(asset, ref mNameStringDict);
            return;
        }
        if (mUIStringDict.Count == 0)
        {
            ReadString(asset, ref mUIStringDict);
            return;
        }
        if (mPropsStringDict.Count == 0)
        {
            ReadString(asset, ref mPropsStringDict);
            return;
        }
        if (mSystemStringDict.Count == 0)
        {
            ReadString(asset, ref mSystemStringDict);
            return;
        }
    }
Example #3
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        m_data = new List <TD_Eff>();

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }

        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TD_Eff item;

        for (int i = 0; i < xmlNodeListLength; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item                     = new TD_Eff();
            item.id                  = node.GetIntValue("effect_id");
            item.reference           = node.GetStringValue("reference");
            item.condition           = node.GetIntValue("condition");
            item.time_type           = node.GetIntValue("time_type");
            item.time_value          = node.GetIntValue("time_value");
            item.choose              = node.GetIntValue("choose");
            item.target              = node.GetIntValue("target");
            item.effect              = node.GetIntValue("effect");
            item.effect_value        = node.GetIntValue("effect_value");
            item.effect_value_c_rate = node.GetIntValue("effect_value_c_rate");
            item.fight_value         = node.GetIntValue("fight_value");
            item.valid_type          = node.GetIntValue("valid_type");
            item.valid_value         = node.GetIntValue("valid_value");

            m_data.Add(item);
        }
        asset = null;

        if (null != m_callBack)
        {
            m_callBack();
            m_callBack = null;
        }

        base.onloaded(data);
    }
Example #4
0
 public virtual void onloaded(AssetBundles.NormalRes normalRes)
 {
     if (null != m_onLoaded)
     {
         m_onLoaded();
         m_onLoaded = null;
     }
 }
Example #5
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        m_data = new List <TD_Skill>();

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }

        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TD_Skill item;

        for (int i = 0; i < xmlNodeListLength; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item               = new TD_Skill();
            item.id            = node.GetIntValue("skill_id");
            item.res           = node.GetStringValue("res");
            item.des           = node.GetStringValue("skill_dis");
            item.name          = node.GetStringValue("name");
            item.point         = node.GetIntValue("skill_exp");
            item.animation     = node.GetStringValue("animation");
            item.hero_out      = node.GetStringValue("hero_out");
            item.hero_back     = node.GetStringValue("hero_back");
            item.a_trigger     = node.GetStringValue("a_trigger");
            item.a_value       = node.GetStringValue("a_value");
            item.effect_target = node.GetStringValue("effect_target");

            m_data.Add(item);
        }
        asset = null;

        if (null != m_callBack)
        {
            m_callBack();
            m_callBack = null;
        }

        base.onloaded(data);
    }
Example #6
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        if (null != m_confidata)
        {
            return;
        }
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        m_confidata = new Dictionary <int, MentalityMaxInfo>();

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode        childNode;
            MentalityMaxInfo childItem;
            childNode          = xmlNodeList[i] as TbXmlNode;
            childItem          = new MentalityMaxInfo();
            childItem.type     = childNode.GetIntValue("Type");
            childItem.shoot    = childNode.GetIntValue("shoot");
            childItem.pass     = childNode.GetIntValue("pass");
            childItem.reel     = childNode.GetIntValue("reel");
            childItem.control  = childNode.GetIntValue("control");
            childItem.def      = childNode.GetIntValue("def");
            childItem.trick    = childNode.GetIntValue("trick");
            childItem.steal    = childNode.GetIntValue("steal");
            childItem.keep     = childNode.GetIntValue("keep");
            childItem.material = childNode.GetStringValue("material");
            if (m_confidata.ContainsKey(childItem.type))
            {
                m_confidata[childItem.type] = childItem;
            }
            else
            {
                m_confidata.Add(childItem.type, childItem);
            }
        }
        asset = null;
        base.onloaded(data);
    }
Example #7
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }


        base.onloaded(data);
    }
Example #8
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node    = xmlNodeList[i] as TbXmlNode;
            int       id      = node.GetIntValue("ID");
            string    surname = node.GetStringValue("TheSurname");
            string    name    = node.GetStringValue("TheName");
            if (surname != string.Empty)
            {
                if (surnameList.ContainsKey(id))
                {
                    surnameList[id] = surname;
                }
                else
                {
                    surnameList.Add(id, surname);
                }
            }
            if (nameList.ContainsKey(id))
            {
                nameList[id] = name;
            }
            else
            {
                nameList.Add(id, name);
            }
        }
        asset = null;

        base.onloaded(data);
    }
Example #9
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        m_data = new List <TD_SkillPrefabInfo>();

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }

        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TD_SkillPrefabInfo item;

        for (int i = 0; i < xmlNodeListLength; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item            = new TD_SkillPrefabInfo();
            item.id         = node.GetStringValue("id");
            item.scale      = node.GetStringValue("scale");
            item.rootScale  = node.GetStringValue("rootScale");
            item.enemyPoint = node.GetStringValue("enemyPoint");
            item.selfPoint  = node.GetStringValue("selfPoint");
            item.haveEnemy  = node.GetBooleanValue("haveEnemy");

            m_data.Add(item);
        }
        asset = null;

        if (null != m_callBack)
        {
            m_callBack();
            m_callBack = null;
        }

        base.onloaded(data);
    }
Example #10
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        m_data = new List <TD_Card>();

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }

        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TD_Card item;

        for (int i = 0; i < xmlNodeListLength; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item            = new TD_Card();
            item.id         = node.GetIntValue("card_id");
            item.res        = node.GetStringValue("res");
            item.name       = node.GetStringValue("name");
            item.type       = (E_CardType)node.GetIntValue("card_type");
            item.type1      = node.GetStringValue("card_type1");
            item.skill_list = node.GetStringValue("skill_list");

            m_data.Add(item);
        }
        asset = null;

        if (null != m_callBack)
        {
            m_callBack();
            m_callBack = null;
        }

        base.onloaded(data);
    }
Example #11
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        m_data = new Dictionary <int, TD_Skill>();

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }

        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TD_Skill item;

        for (int i = 0; i < xmlNodeListLength; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item      = new TD_Skill();
            item.ID   = node.GetIntValue("ID");
            item.name = node.GetStringValue("name");
            item.type = (Skill_Type)node.GetIntValue("type");
            item.icon = node.GetStringValue("icon");
            item.des  = node.GetStringValue("des");

            m_data[item.ID] = item;
        }

        asset = null;

        if (null != m_callBack)
        {
            m_callBack();
            m_callBack = null;
        }

        base.onloaded(data);
    }
Example #12
0
    static void LoadOfficialConfig(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        OfficalInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info                 = new OfficalInfo();
            info.id              = node.GetIntValue("ID");
            info.type            = node.GetIntValue("officialType");
            info.name            = node.GetStringValue("name");
            info.limit           = node.GetIntValue("limit");
            info.needLevel       = node.GetIntValue("needLevel");
            info.needCost        = node.GetStringValue("needCost");
            info.admit           = node.GetIntValue("admit");
            info.maxAchievements = node.GetIntValue("maxAchievements");
            info.question        = node.GetStringValue("question");
            info.everyDayReward  = node.GetIntValue("everyDayReward");
            info.havePermission  = node.GetStringValue("havePermission");
            info.guildLevel      = node.GetIntValue("guildLevel");
            info.signUpLimit     = node.GetIntValue("signUpLimit");
            if (configList.ContainsKey(info.id))
            {
                configList[info.id] = info;
            }
            else
            {
                configList.Add(info.id, info);
            }
        }
        asset = null;
    }
Example #13
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        m_teamData = new Dictionary <int, TD_Clone>();

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }

        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TD_Clone item;

        for (int i = 0; i < xmlNodeListLength; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item           = new TD_Clone();
            item.id        = node.GetIntValue("ID");
            item.name      = node.GetStringValue("name");
            item.openLv    = node.GetIntValue("openLv");
            item.targetDes = node.GetStringValue("targetDes");

            m_teamData[item.id] = item;
        }
        asset = null;

        if (null != m_callBack)
        {
            m_callBack();
            m_callBack = null;
        }

        base.onloaded(data);
    }
Example #14
0
    static void LoadClothesConfig(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        ClothesInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info             = new ClothesInfo();
            info.configID    = node.GetIntValue("id");
            info.addValue    = node.GetStringValue("addvalue");
            info.lockAdd     = node.GetStringValue("lockadd");
            info.initstar    = node.GetIntValue("initstar");
            info.type        = node.GetIntValue("type");
            info.lockLevel   = node.GetIntValue("locklevel");
            info.maxLevel    = node.GetIntValue("maxlevel");
            info.maxstar     = node.GetIntValue("maxstar");
            info.worthValue  = node.GetIntValue("worthvalue");
            info.percentType = node.GetIntValue("percenttype");
            if (configList.ContainsKey(info.configID))
            {
                configList[info.configID] = info;
            }
            else
            {
                configList.Add(info.configID, info);
            }
        }
        asset = null;
    }
Example #15
0
    /// <summary>
    /// 加载商城配置
    /// </summary>
    public static void LoadShopItemConfig(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        ShopItemInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info           = new ShopItemInfo();
            info.itemID    = node.GetStringValue("shopItemID");
            info.itemType  = node.GetIntValue("ItemType");
            info.tabType   = node.GetIntValue("TabType");
            info.limitTime = node.GetIntValue("limitTimes");
            info.itemPrice = node.GetIntValue("price");
            info.moneyType = node.GetIntValue("moneyType");
            info.disCount  = node.GetIntValue("disCount");
            info.recommend = node.GetIntValue("recommend");
            info.isLimit   = node.GetIntValue("isLimit");
            if (shopList.ContainsKey(info.itemID))
            {
                shopList[info.itemID] = info;
            }
            else
            {
                shopList.Add(info.itemID, info);
            }
        }
        asset = null;
    }
Example #16
0
    /// <summary>
    /// 加载道具配置
    /// </summary>
    public static void LoadItemConfig(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        ItemInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info              = new ItemInfo();
            info.itemID       = node.GetStringValue("ItemId");
            info.itemType     = node.GetIntValue("ItemType");
            info.color        = node.GetIntValue("Color");
            info.itemName     = node.GetStringValue("ItemName");
            info.itemPrice    = node.GetIntValue("ItemPrice");
            info.tabType      = node.GetIntValue("TabType");
            info.isTogether   = node.GetIntValue("isTogethe");
            info.qualityOrder = node.GetIntValue("worthValue");
            if (itemList.ContainsKey(info.itemID))
            {
                itemList[info.itemID] = info;
            }
            else
            {
                itemList.Add(info.itemID, info);
            }
        }
        asset = null;
    }
Example #17
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        if (null != m_confidata)
        {
            return;
        }
        m_confidata = new Dictionary <int, TD_PlayerPosition>();

        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }
        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TD_PlayerPosition item;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item            = new TD_PlayerPosition();
            item.pos        = node.GetIntValue("pos");
            item.atkPer     = node.GetFloatValue("atkPer");
            item.defPer     = node.GetFloatValue("defPer");
            item.controlPer = node.GetFloatValue("controlPer");
            item.passPer    = node.GetFloatValue("passPer");
            item.atkEnable  = node.GetIntValue("atkEnable") == 1 ? true : false;
            item.adaptDef   = node.GetStringValue("adaptDef");

            m_confidata[item.pos] = item;
        }
        asset = null;
        base.onloaded(data);
    }
Example #18
0
    static void LoadCupRewardInfo(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        CupRewardInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info       = new CupRewardInfo();
            info.id    = node.GetIntValue("id");
            info.cup1  = node.GetStringValue("cup1");
            info.star1 = node.GetIntValue("star1");
            info.cup2  = node.GetStringValue("cup2");
            info.star2 = node.GetIntValue("star2");
            info.cup3  = node.GetStringValue("cup3");
            info.star3 = node.GetIntValue("star3");
            info.cup4  = node.GetStringValue("cup4");
            info.star4 = node.GetIntValue("star4");
            if (CupconfigDic.ContainsKey(info.id))
            {
                CupconfigDic[info.id] = info;
            }
            else
            {
                CupconfigDic.Add(info.id, info);
            }
        }
        asset = null;
    }
    public override void onloaded(AssetBundles.NormalRes data)
    {
        if (null != m_confidata)
        {
            return;
        }
        m_confidata = new Dictionary <int, TD_PositionAttribute>();

        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }
        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TD_PositionAttribute item;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item          = new TD_PositionAttribute();
            item.pos      = node.GetIntValue("pos");
            item.powerPer = node.GetFloatValue("powerPer");
            item.distance = node.GetFloatValue("distance");
            item.isBound  = node.GetBooleanValue("bound");

            m_confidata[item.pos] = item;
        }
        asset = null;
        base.onloaded(data);
    }
Example #20
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        if (null != m_confidata)
        {
            return;
        }
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        m_confidata = new Dictionary <int, TD_MatchArray>();
        TD_MatchArray item;

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("root/item");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;

            item       = new TD_MatchArray();
            item.id    = node.GetIntValue("id");
            item.name  = node.GetStringValue("name");
            item.array = node.GetStringValue("array0").Split(',');

            m_confidata[item.id] = item;
        }

        asset = null;
        base.onloaded(data);
    }
Example #21
0
    static void LoadClothesMapConfig(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        ClothesMapInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info            = new ClothesMapInfo();
            info.mapID      = node.GetIntValue("id");
            info.addValue   = node.GetStringValue("addvalue");
            info.reward     = node.GetStringValue("reward");
            info.suitName   = node.GetStringValue("suiName");
            info.spriteName = node.GetStringValue("spriteName");
            if (configList.ContainsKey(info.mapID))
            {
                configList[info.mapID] = info;
            }
            else
            {
                configList.Add(info.mapID, info);
            }
        }
        asset = null;
    }
Example #22
0
    static void LoadCupRewardInfo(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        TD_CloneLevel info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info        = new TD_CloneLevel();
            info.id     = node.GetIntValue("ID");
            info.name   = node.GetStringValue("name");
            info.levels = node.GetStringValue("levels");
            info.cup1   = node.GetStringValue("cup1");
            info.star1  = node.GetIntValue("star1");
            info.cup2   = node.GetStringValue("cup2");
            info.star2  = node.GetIntValue("star2");
            info.cup3   = node.GetStringValue("cup3");
            info.star3  = node.GetIntValue("star3");
            info.cup4   = node.GetStringValue("cup4");
            info.star4  = node.GetIntValue("star4");

            CupconfigDic[info.id] = info;
        }
        asset = null;
    }
Example #23
0
    static void LoadClothesLevelInfo(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        ClothesLevelInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info           = new ClothesLevelInfo();
            info.levelId   = node.GetIntValue("id");
            info.addValue  = node.GetIntValue("addvalue");
            info.lockValue = node.GetIntValue("lockvalue");
            info.needExp   = node.GetIntValue("needexp");
            info.needMoney = node.GetIntValue("needmoney");
            if (configList.ContainsKey(info.levelId))
            {
                configList[info.levelId] = info;
            }
            else
            {
                configList.Add(info.levelId, info);
            }
        }
        asset = null;
    }
Example #24
0
    /// <summary>
    /// 加载材料配置
    /// </summary>
    public static void LoadMaterialConfig(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        MaterialItemInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info            = new MaterialItemInfo();
            info.itemID     = node.GetStringValue("ID");
            info.needAmount = node.GetIntValue("combineCount");
            info.materialId = node.GetIntValue("materialID");
            if (materialList.ContainsKey(info.itemID))
            {
                materialList[info.itemID] = info;
            }
            else
            {
                materialList.Add(info.itemID, info);
            }
        }
        asset = null;
    }
Example #25
0
    static void LoadClothesConfig(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        BabyStar info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info          = new BabyStar();
            info.id       = node.GetIntValue("id");
            info.extent   = node.GetStringValue("extent");
            info.state    = node.GetIntValue("state");
            info.addvalue = node.GetStringValue("addvalue");
            if (configList.ContainsKey(info.id))
            {
                configList[info.id] = info;
            }
            else
            {
                configList.Add(info.id, info);
            }
        }
        asset = null;
    }
Example #26
0
    public static void LoadSuitConfig(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        SuitInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info         = new SuitInfo();
            info.id      = node.GetIntValue("id");
            info.nameID  = node.GetStringValue("name");
            info.equipId = node.GetStringValue("equiq");
            info.suitAdd = node.GetStringValue("suitadd");
            if (configList.ContainsKey(info.id))
            {
                configList[info.id] = info;
            }
            else
            {
                configList.Add(info.id, info);
            }
        }
        asset = null;
    }
Example #27
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        RewardInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info          = new RewardInfo();
            info.itemID   = node.GetStringValue("ID");
            info.itemType = node.GetIntValue("Type");
            info.amount   = node.GetIntValue("Contract");
            if (configList.ContainsKey(info.itemID))
            {
                configList[info.itemID] = info;
            }
            else
            {
                configList.Add(info.itemID, info);
            }
        }
        asset = null;
        base.onloaded(data);
    }
Example #28
0
    static void LoadLevelRewardInfo(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;
        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        LevelRewardInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info          = new LevelRewardInfo();
            info.id       = node.GetIntValue("id");
            info.exp      = node.GetIntValue("exp");
            info.Euro     = node.GetIntValue("Euro");
            info.preview1 = node.GetStringValue("preview1");
            if (levelconfigDic.ContainsKey(info.id))
            {
                levelconfigDic[info.id] = info;
            }
            else
            {
                levelconfigDic.Add(info.id, info);
            }
        }
        asset = null;
    }
Example #29
0
    public override void onloaded(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }

        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }

        TbXmlNode node = xmlNodeList[0] as TbXmlNode;

        offX      = node.GetFloatValue("offX");
        offY      = node.GetFloatValue("offY");
        offZ      = node.GetFloatValue("offZ");
        pX        = node.GetFloatValue("pX");
        pY        = node.GetFloatValue("pY");
        pZ        = node.GetFloatValue("pZ");
        rX        = node.GetFloatValue("rX");
        rY        = node.GetFloatValue("rY");
        rZ        = node.GetFloatValue("rZ");
        bound     = node.GetStringValue("bound");
        fieldView = node.GetFloatValue("fieldView");

        asset = null;
        base.onloaded(data);
    }
Example #30
0
    /// <summary>
    /// 加载消耗品配置
    /// </summary>
    public static void LoadConsuleConfig(AssetBundles.NormalRes data)
    {
        byte[] asset = (data as AssetBundles.BytesRes).m_bytes;

        if (asset == null)
        {
            return;
        }

        TbXmlNode docNode = TbXml.Load(asset).docNode;

        if (docNode == null)
        {
            return;
        }
        List <TbXmlNode> xmlNodeList = docNode.GetNodes("Object/Property");
        int xmlNodeListLength        = xmlNodeList.Count;

        if (xmlNodeListLength < 1)
        {
            return;
        }
        ConsumeItemInfo info;

        for (int i = 0; i < xmlNodeList.Count; ++i)
        {
            TbXmlNode node = xmlNodeList[i] as TbXmlNode;
            info           = new ConsumeItemInfo();
            info.itemID    = node.GetStringValue("id");
            info.propValue = node.GetIntValue("addValue");
            if (consumemList.ContainsKey(info.itemID))
            {
                consumemList[info.itemID] = info;
            }
            else
            {
                consumemList.Add(info.itemID, info);
            }
        }
        asset = null;
    }