少年修仙传客户端代码仓库
client_Hale
2018-11-15 93d44472efc6c531c83da21bedac829a2e25d4a5
Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
6个文件已添加
12个文件已修改
583 ■■■■■ 已修改文件
Core/GameEngine/Model/Config/IceLodeStarAwardConfig.cs 53 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/GameEngine/Model/Config/IceLodeStarAwardConfig.cs.meta 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/GameEngine/Model/Config/LoadingBackGroundConfig.cs 50 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/GameEngine/Model/Config/LoadingBackGroundConfig.cs.meta 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/GameEngine/Model/Config/MapResourcesConfig.cs 61 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/GameEngine/Model/Config/MapResourcesConfig.cs.meta 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/GameEngine/Model/ConfigManager.cs 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/GameEngine/Model/TelPartialConfig/tagStoreConfig.cs 65 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA3B7_tagMCBOSSAttactCnt.cs 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/NetworkPackage/ServerPack/HA3_Function/HA3B7_tagMCBOSSAttactCnt.cs 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Dungeon/DemonTreasureDungeonVictoryWin.cs 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Dungeon/DungeonGradeWin.cs 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Dungeon/IceCrystalVeinModel.cs 84 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Dungeon/IceCrystalVeinModel.cs.meta 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Dungeon/IceCrystalVeinWin.cs 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Dungeon/TreasureDungeonMissionHintWin.cs 28 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Loading/LoadingWin.cs 108 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/WindowBase/ModelCenter.cs 1 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/GameEngine/Model/Config/IceLodeStarAwardConfig.cs
New file
@@ -0,0 +1,53 @@
//--------------------------------------------------------
//    [Author]:            第二世界
//    [  Date ]:           Thursday, November 15, 2018
//--------------------------------------------------------
using UnityEngine;
using System;
namespace TableConfig {
    public partial class IceLodeStarAwardConfig : ConfigBase {
        public int id { get ; private set ; }
        public int index { get ; private set ; }
        public int Star { get ; private set ; }
        public string LV { get ; private set; }
        public string ItemList { get ; private set; }
        public int Type { get ; private set ; }
        public override string getKey()
        {
            return id.ToString();
        }
        public override void Parse() {
            try
            {
                id=IsNumeric(rawContents[0]) ? int.Parse(rawContents[0]):0;
                index=IsNumeric(rawContents[1]) ? int.Parse(rawContents[1]):0;
                Star=IsNumeric(rawContents[2]) ? int.Parse(rawContents[2]):0;
                LV = rawContents[3].Trim();
                ItemList = rawContents[4].Trim();
                Type=IsNumeric(rawContents[5]) ? int.Parse(rawContents[5]):0;
            }
            catch (Exception ex)
            {
                DebugEx.Log(ex);
            }
        }
    }
}
Core/GameEngine/Model/Config/IceLodeStarAwardConfig.cs.meta
New file
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: b18277562fc6e994c906d41cb5c14c5b
timeCreated: 1542267230
licenseType: Free
MonoImporter:
  serializedVersion: 2
  defaultReferences: []
  executionOrder: 0
  icon: {instanceID: 0}
  userData:
  assetBundleName:
  assetBundleVariant:
Core/GameEngine/Model/Config/LoadingBackGroundConfig.cs
New file
@@ -0,0 +1,50 @@
//--------------------------------------------------------
//    [Author]:            第二世界
//    [  Date ]:           Thursday, November 15, 2018
//--------------------------------------------------------
using UnityEngine;
using System;
namespace TableConfig {
    public partial class LoadingBackGroundConfig : ConfigBase {
        public int id { get ; private set ; }
        public string[] icons;
        public string levelLimit { get ; private set; }
        public string name { get ; private set; }
        public string description { get ; private set; }
        public override string getKey()
        {
            return id.ToString();
        }
        public override void Parse() {
            try
            {
                id=IsNumeric(rawContents[0]) ? int.Parse(rawContents[0]):0;
                icons = rawContents[1].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
                levelLimit = rawContents[2].Trim();
                name = rawContents[3].Trim();
                description = rawContents[4].Trim();
            }
            catch (Exception ex)
            {
                DebugEx.Log(ex);
            }
        }
    }
}
Core/GameEngine/Model/Config/LoadingBackGroundConfig.cs.meta
New file
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 791645468791ce74c84280782740fa99
timeCreated: 1542267123
licenseType: Pro
MonoImporter:
  serializedVersion: 2
  defaultReferences: []
  executionOrder: 0
  icon: {instanceID: 0}
  userData:
  assetBundleName:
  assetBundleVariant:
Core/GameEngine/Model/Config/MapResourcesConfig.cs
@@ -1,14 +1,14 @@
//--------------------------------------------------------
//    [Author]:            第二世界
//    [  Date ]:           Friday, May 18, 2018
//--------------------------------------------------------
using UnityEngine;
using System;
namespace TableConfig {
//--------------------------------------------------------
//    [Author]:            第二世界
//    [  Date ]:           Thursday, November 15, 2018
//--------------------------------------------------------
using UnityEngine;
using System;
namespace TableConfig {
    public partial class MapResourcesConfig : ConfigBase {
        public int ID { get ; private set ; }
@@ -22,17 +22,14 @@
        public Vector3 MapOffset { get ; private set; } 
        public int[] Effect;
        public int Music { get ; private set ; }
        public string[] LoadingBG;
        public string LoadName { get ; private set; }
        public string LoadDescription { get ; private set; }
        public int ShowBOSSTime { get ; private set ; }
        public override string getKey()
        {
            return ID.ToString();
        }
        public override void Parse() {
        }
        public override void Parse() {
            try
            {
                ID=IsNumeric(rawContents[0]) ? int.Parse(rawContents[0]):0; 
@@ -62,24 +59,18 @@
            
                Music=IsNumeric(rawContents[10]) ? int.Parse(rawContents[10]):0; 
            
                LoadingBG = rawContents[11].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
                LoadName = rawContents[12].Trim();
                LoadDescription = rawContents[13].Trim();
                ShowBOSSTime=IsNumeric(rawContents[14]) ? int.Parse(rawContents[14]):0;
                ShowBOSSTime=IsNumeric(rawContents[11]) ? int.Parse(rawContents[11]):0;
            }
            catch (Exception ex)
            {
                DebugEx.Log(ex);
            }
        }
    }
}
            }
        }
    }
}
Core/GameEngine/Model/Config/MapResourcesConfig.cs.meta
@@ -1,6 +1,6 @@
fileFormatVersion: 2
guid: 8f17a96ef841bb74dafcec974bb4e7f5
timeCreated: 1526625853
timeCreated: 1542269954
licenseType: Pro
MonoImporter:
  serializedVersion: 2
Core/GameEngine/Model/ConfigManager.cs
@@ -205,6 +205,9 @@
        AddAsyncTask<GuardConfig>();
        AddAsyncTask<MarketQueryConfig>();
        AddAsyncTask<TreasureDungeonConfig>();
        AddAsyncTask<LoadingBackGroundConfig>();
        AddAsyncTask<IceLodeStarAwardConfig>();
        while (!AllCompleted())
        {
            var completedCount = 0;
Core/GameEngine/Model/TelPartialConfig/tagStoreConfig.cs
@@ -8,12 +8,16 @@
    {
        private static Dictionary<StoreItem, StoreConfig> s_StoreItemDict = new Dictionary<StoreItem, StoreConfig>();
        private static Dictionary<int, List<StoreConfig>> storeConfigs = new Dictionary<int, List<StoreConfig>>();
        static readonly int[] shop1Types = new int[] { 2, 3 };
        static readonly int[] shop2Types = new int[] { 4 };
        public void OnConfigParseCompleted()
        {
            if (ShopType == 0) return;
            var _storeItem = new StoreItem()
            {
                shopType = this.ShopType,
                item = this.ItemID,
                type = this.MoneyType,
            };
@@ -31,16 +35,60 @@
            list.Add(this);
        }
        public static StoreConfig GetStoreCfg(int _item, int _moneyType)
        public static StoreConfig GetStoreCfg(int _item, int _moneyType, int shopType = 0)
        {
            var _storeItem = new StoreItem()
            if (shopType != 0)
            {
                item = _item,
                type = _moneyType,
            };
            if (s_StoreItemDict.ContainsKey(_storeItem))
                var storeItem = new StoreItem()
                {
                    item = _item,
                    type = _moneyType,
                    shopType = shopType,
                };
                if (s_StoreItemDict.ContainsKey(storeItem))
                {
                    return s_StoreItemDict[storeItem];
                }
            }
            else
            {
                return s_StoreItemDict[_storeItem];
                switch (_moneyType)
                {
                    case 1:
                        {
                            for (int i = 0; i < shop1Types.Length; i++)
                            {
                                var storeItem = new StoreItem()
                                {
                                    item = _item,
                                    type = _moneyType,
                                    shopType = shop1Types[i],
                                };
                                if (s_StoreItemDict.ContainsKey(storeItem))
                                {
                                    return s_StoreItemDict[storeItem];
                                }
                            }
                        }
                        break;
                    case 2:
                        {
                            for (int i = 0; i < shop2Types.Length; i++)
                            {
                                var storeItem = new StoreItem()
                                {
                                    item = _item,
                                    type = _moneyType,
                                    shopType = shop2Types[i],
                                };
                                if (s_StoreItemDict.ContainsKey(storeItem))
                                {
                                    return s_StoreItemDict[storeItem];
                                }
                            }
                        }
                        break;
                }
            }
            return null;
        }
@@ -52,13 +100,14 @@
        public struct StoreItem
        {
            public int shopType;
            public int item;
            public int type;
            public override bool Equals(object x)
            {
                StoreItem _storeItem = (StoreItem)x;
                return this.item == _storeItem.item && this.type == _storeItem.type;
                return this.item == _storeItem.item && this.type == _storeItem.type && this.shopType == _storeItem.shopType;
            }
            public override int GetHashCode()
Core/NetworkPackage/DTCFile/ServerPack/HA3_Function/DTCA3B7_tagMCBOSSAttactCnt.cs
@@ -27,11 +27,11 @@
            switch (info.BossType)
            {
                case 0:
                    worldBossModel.wearyValue = info.KillCnt;
                    worldBossModel.extraBossWearyValue = info.ItemAddCnt;
                    worldBossModel.wearyValue = (int)info.KillCnt;
                    worldBossModel.extraBossWearyValue = (int)info.ItemAddCnt;
                    break;
                case 2:
                    dogzDungeonModel.wearyValue = info.KillCnt;
                    dogzDungeonModel.wearyValue = (int)info.KillCnt;
                    break;
            }
        }
Core/NetworkPackage/ServerPack/HA3_Function/HA3B7_tagMCBOSSAttactCnt.cs
@@ -21,16 +21,16 @@
        {
            KillCntInfoList[i] = new tagMCBossCntInfo();
            TransBytes(out KillCntInfoList[i].BossType, vBytes, NetDataType.BYTE);
            TransBytes(out KillCntInfoList[i].KillCnt, vBytes, NetDataType.BYTE);
            TransBytes(out KillCntInfoList[i].ItemAddCnt, vBytes, NetDataType.BYTE);
            TransBytes(out KillCntInfoList[i].KillCnt, vBytes, NetDataType.DWORD);
            TransBytes(out KillCntInfoList[i].ItemAddCnt, vBytes, NetDataType.DWORD);
        }
    }
    public struct tagMCBossCntInfo
    {
        public byte BossType;        //编号类型0-世界boss 1-boss之家
        public byte KillCnt;        //击杀次数
        public byte ItemAddCnt;        //物品增加次数
        public uint KillCnt;        //击杀次数
        public uint ItemAddCnt;        //物品增加次数
    }
}
System/Dungeon/DemonTreasureDungeonVictoryWin.cs
@@ -17,6 +17,8 @@
        [SerializeField] PropertyBehaviour[] m_Propertys;
        [SerializeField] Button m_ChallengeNextLevel;
        public static event Action challengeNextEvent;
        TreasureModel model
        {
            get { return ModelCenter.Instance.GetModel<TreasureModel>(); }
@@ -63,6 +65,7 @@
                    {
                        m_Propertys[index].gameObject.SetActive(true);
                        m_Propertys[index].Display(key, propertyDict[key]);
                        index++;
                    }
                }
            }
@@ -84,6 +87,13 @@
                    pak.ActionType = 0;
                    pak.ActionInfo = 0;
                    GameNetSystem.Instance.SendInfo(pak);
                    dungeonModel.UpdateCoolDown(DungeonCoolDownType.LeaveMap, 0);
                    dungeonModel.UpdateCoolDown(DungeonCoolDownType.TowerTake, 0);
                    CloseClick();
                    if (challengeNextEvent != null)
                    {
                        challengeNextEvent();
                    }
                }
            }
        }
System/Dungeon/DungeonGradeWin.cs
@@ -35,13 +35,12 @@
        [SerializeField] GameObject gradeContainer;
        [SerializeField] GameObject expContainer;
        [SerializeField] RectTransform[] moveRects;
        DateTime endTime;
        DateTime dungeonEndTime;
        [SerializeField] RectTransform[] moveRects;
        private bool isCanContinue = true;
        private bool exitDungeonStage = false;
        private DungeonModel model
        {
@@ -67,11 +66,16 @@
            SetTween(gradePosTween, gradeScaleTween, 0);
            SetTween(expPosTween, expScaleTween, 0);
            dungeonEndTime = model.GetCoolDownEndTime(DungeonCoolDownType.TowerTake);
            endTime = model.GetCoolDownEndTime(DungeonCoolDownType.FlagTake);
            expContainer.SetActive(false);
            isCanContinue = true;
            dungeonEndTime = model.GetCoolDownEndTime(DungeonCoolDownType.TowerTake);
            endTime = model.GetCoolDownEndTime(DungeonCoolDownType.FlagTake);
            var exitTime = model.GetCoolDownEndTime(DungeonCoolDownType.LeaveMap);
            exitDungeonStage = exitTime > DateTime.Now;
            if (exitDungeonStage)
            {
                DungeonCoolDownEvent(DungeonCoolDownType.LeaveMap);
            }
        }
        private void OnEnable()
@@ -140,11 +144,8 @@
                    endTime = model.GetCoolDownEndTime(type);
                    break;
                case DungeonCoolDownType.LeaveMap:
                    if (isCanContinue)
                    {
                        surplusTime.text = Language.Get("DungeonGrade_5", GetStar(model.mission.grade));
                    }
                    isCanContinue = false;
                    surplusTime.text = Language.Get("DungeonGrade_5", GetStar(model.mission.grade));
                    exitDungeonStage = true;
                    break;
            }
        }
@@ -206,7 +207,7 @@
        protected override void LateUpdate()
        {
            base.LateUpdate();
            if (isCanContinue)
            if (!exitDungeonStage)
            {
                if (model.mission.grade > 1)
                {
@@ -232,7 +233,7 @@
                    surplusTime.text = Language.Get("DungeonGrade_4", TimeUtility.SecondsToHMSCHSRetain((int)surplus.TotalSeconds, false, false));
                    if (surplus.Equals(TimeSpan.Zero))
                    {
                        isCanContinue = false;
                        exitDungeonStage = true;
                        surplusTime.text = Language.Get("DungeonGrade_1");
                    }
                }
System/Dungeon/IceCrystalVeinModel.cs
New file
@@ -0,0 +1,84 @@
//--------------------------------------------------------
//    [Author]:           第二世界
//    [  Date ]:           Thursday, November 15, 2018
//--------------------------------------------------------
//冰晶矿脉新
using System;
using System.Collections.Generic;
using TableConfig;
using Snxxz.UI;
[XLua.LuaCallCSharp]
public class IceLodeStarAwardClass
{
    public int Index;
    public int Star;
    public int MinLv;
    public int MaxLv;
    public int ItemID;
    public int ItemCount;
    public int IsBind;
    public int Type;
}
public class IceCrystalVeinModel : Model, IBeforePlayerDataInitialize, IPlayerLoginOk
{
    public Dictionary<int, IceLodeStarAwardClass> DicIceLodeStarAward = new Dictionary<int, IceLodeStarAwardClass>();
    public override void Init()
    {
        Assignment();
    }
    public void OnBeforePlayerDataInitialize()
    {
    }
    public override void UnInit()
    {
    }
    public void OnPlayerLoginOk()
    {
    }
    private void Assignment()
    {
        if (DicIceLodeStarAward.Count <= 0)
        {
            var config = Config.Instance.GetAllValues<IceLodeStarAwardConfig>();
            foreach (var Value in config)
            {
                if (!DicIceLodeStarAward.ContainsKey(Value.id))
                {
                    IceLodeStarAwardClass iceLodeStar = new IceLodeStarAwardClass();
                    iceLodeStar.Index = Value.index;
                    iceLodeStar.Star = Value.Star;
                    var _jsonData = LitJson.JsonMapper.ToObject(Value.LV);
                    if (_jsonData.Count > 0)
                    {
                        iceLodeStar.MinLv = int.Parse(_jsonData[0].ToString());
                        iceLodeStar.MaxLv = int.Parse(_jsonData[1].ToString());
                    }
                    var jsonData = LitJson.JsonMapper.ToObject(Value.ItemList);
                    if (jsonData.Count > 0)
                    {
                        iceLodeStar.ItemID = int.Parse((jsonData[0][0]).ToString());
                        iceLodeStar.ItemCount = int.Parse((jsonData[0][1]).ToString());
                        iceLodeStar.IsBind = int.Parse((jsonData[0][2]).ToString());
                    }
                    iceLodeStar.Type = Value.Type;
                    DicIceLodeStarAward.Add(Value.id, iceLodeStar);
                }
            }
        }
    }
}
System/Dungeon/IceCrystalVeinModel.cs.meta
New file
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 60541ff2122967249beb1f30d9fdd254
timeCreated: 1542267471
licenseType: Free
MonoImporter:
  serializedVersion: 2
  defaultReferences: []
  executionOrder: 0
  icon: {instanceID: 0}
  userData:
  assetBundleName:
  assetBundleVariant:
System/Dungeon/IceCrystalVeinWin.cs
@@ -22,11 +22,12 @@
        [SerializeField] Transform m_GridMiddle;//中间组
        [SerializeField] Transform m_GridBottom;//底层组
        ItemTipsModel _itemTipsModel;
        ItemTipsModel itemTipsModel { get { return _itemTipsModel ?? (_itemTipsModel = ModelCenter.Instance.GetModel<ItemTipsModel>()); } }
        ItemTipsModel itemTipsModel { get { return _itemTipsModel ?? (_itemTipsModel = ModelCenter.Instance.GetModel<ItemTipsModel>()); } }
        IceCrystalVeinModel m_IceCrystalVeinModel;
        IceCrystalVeinModel iceCrystalVeinModel { get { return m_IceCrystalVeinModel ?? (m_IceCrystalVeinModel = ModelCenter.Instance.GetModel<IceCrystalVeinModel>()); } }
        private int IndexSelect = 1;
        private List<int> IceCrystalVeinMiddle = new List<int>();
        private List<int> IceCrystalVeinStarBottom = new List<int>();
        private List<int> IceCrystalVeinBottom = new List<int>();
        private List<IceLodeStarAwardClass> IceLodeStarAwardList = new List<IceLodeStarAwardClass>();
        #region Built-in
        protected override void BindController()
        {
@@ -36,17 +37,6 @@
            for (int i = 0; i < IceCrystalVeinReward.Length; i++)
            {
                IceCrystalVeinMiddle.Add(IceCrystalVeinReward[i]);
            }
            var _IceCrystalVeinStarReward = Config.Instance.Get<FuncConfigConfig>("IceCrystalVeinStarReward");
            int[] _IceCrystalVeinStarBottom = ConfigParse.GetMultipleStr<int>(_IceCrystalVeinStarReward.Numerical1);
            for (int i = 0; i < _IceCrystalVeinStarBottom.Length; i++)
            {
                IceCrystalVeinStarBottom.Add(_IceCrystalVeinStarBottom[i]);
            }
            int[] _IceCrystalVeinBottom = ConfigParse.GetMultipleStr<int>(_IceCrystalVeinStarReward.Numerical2);
            for (int i = 0; i < _IceCrystalVeinBottom.Length; i++)
            {
                IceCrystalVeinBottom.Add(_IceCrystalVeinBottom[i]);
            }
        }
@@ -60,6 +50,7 @@
        protected override void OnPreOpen()
        {
            OnCreateGridLineCell(m_ScrollerController);
            AddIceLodeStarAwardList();
            SetGridMiddle();
            SetGridBotton();
        }
@@ -158,18 +149,19 @@
            {
                GameObject ObjChild = m_GridBottom.GetChild(i).gameObject;
                if (i < IceCrystalVeinBottom.Count)
                if (i < IceLodeStarAwardList.Count)
                {
                    IceLodeStarAwardClass IceLode = IceLodeStarAwardList[i];
                    ObjChild.SetActive(true);
                    ItemCell _ItemCell = ObjChild.transform.Find("ItemCell_1").GetComponent<ItemCell>();
                    Text TextStar= ObjChild.transform.Find("Text_Star").GetComponent<Text>();
                    TextStar.text = "0/"+IceCrystalVeinStarBottom[i];
                    ItemCellModel cellModel = new ItemCellModel(IceCrystalVeinBottom[i], true, (ulong)1);
                    TextStar.text = "0/"+ IceLode.Star;
                    ItemCellModel cellModel = new ItemCellModel(IceLode.ItemID, true, (ulong)1);
                    _ItemCell.Init(cellModel);
                    int type = i;
                    _ItemCell.cellBtn.SetListener(() =>
                    {
                        ItemAttrData attrData = new ItemAttrData(IceCrystalVeinBottom[type], false, (ulong)1);
                        ItemAttrData attrData = new ItemAttrData(IceLode.ItemID, false, (ulong)1);
                        itemTipsModel.SetItemTipsModel(attrData);
                    });
                }
@@ -179,6 +171,19 @@
                }
            }
        }
        private void AddIceLodeStarAwardList()
        {
            IceLodeStarAwardList.Clear();
            foreach (var key in iceCrystalVeinModel.DicIceLodeStarAward.Keys)
            {
                var Dic = iceCrystalVeinModel.DicIceLodeStarAward[key];
                int Lv = PlayerDatas.Instance.baseData.LV;
                if (Lv >= Dic.MinLv && Lv <= Dic.MaxLv)
                {
                    IceLodeStarAwardList.Add(Dic);
                }
            }
        }
    }
}
System/Dungeon/TreasureDungeonMissionHintWin.cs
@@ -48,6 +48,7 @@
            m_ScreenMoveTo.gameObject.SetActive(false);
            BossNotify.OnNotifyStateEvent += OnNotifyStateEvent;
            BossShowModel.Instance.bossShowCompletedEvent += BossShowCompletedEvent;
            DemonTreasureDungeonVictoryWin.challengeNextEvent += ChallengeNextEvent;
            var allConfigs = Config.Instance.GetAllValues<TreasureConfig>();
            foreach (var value in allConfigs)
@@ -70,6 +71,7 @@
        {
            BossNotify.OnNotifyStateEvent -= OnNotifyStateEvent;
            BossShowModel.Instance.bossShowCompletedEvent -= BossShowCompletedEvent;
            DemonTreasureDungeonVictoryWin.challengeNextEvent -= ChallengeNextEvent;
            m_ContainerDisplay.gameObject.SetActive(true);
        }
@@ -134,6 +136,14 @@
            }
        }
        private void ChallengeNextEvent()
        {
            if (demonTreasureDungeon)
            {
                DisplayDemonTreasureDungeon();
            }
        }
        void DisplayNormalTreasureDungeon()
        {
            var config = Config.Instance.Get<TreasureConfig>(treasureId);
@@ -187,22 +197,12 @@
            demonTreasureDungeon = false;
            if (mapId == 41110)
            {
                var list = model.GetTreasureCategory(TreasureCategory.Demon);
                for (int i = 0; i < list.Count; i++)
                TreasureDungeon treasureDungeon;
                if (model.TryGetTreasureDungeon(mapId, lineId, out treasureDungeon))
                {
                    TreasureDungeon treasureDungeon;
                    if (model.TryGetTreasureDungeon(list[i], out treasureDungeon))
                    if (treasureDungeon.currentLevel < treasureDungeon.maxLevel - 1)
                    {
                        var count = treasureDungeon.dungeonInfos.Count;
                        if (count > 0 && treasureDungeon.dungeonInfos[0].lineId == lineId)
                        {
                            var maxLevel = treasureDungeon.dungeonInfos[count - 1].level;
                            if (treasureDungeon.currentLevel < maxLevel - 1)
                            {
                                demonTreasureDungeon = true;
                                break;
                            }
                        }
                        demonTreasureDungeon = true;
                    }
                }
            }
System/Loading/LoadingWin.cs
@@ -9,6 +9,8 @@
using UnityEngine;
using UnityEngine.UI;
using TableConfig;
using LitJson;
using System.Text.RegularExpressions;
namespace Snxxz.UI
{
@@ -59,49 +61,87 @@
            }
            else
            {
                var playerLevel = PlayerDatas.Instance.baseData.LV == 0 ? PlayerDatas.Instance.loginInfo.LV : PlayerDatas.Instance.baseData.LV;
                var mapResConfig = Config.Instance.Get<MapResourcesConfig>(targetMapResId);
                if (mapResConfig != null && mapResConfig.LoadingBG.Length > 0)
                if (mapResConfig != null)
                {
                    var randomIndex = UnityEngine.Random.Range(0, mapResConfig.LoadingBG.Length > 1 ? mapResConfig.LoadingBG.Length + 1 : 1);
                    if (randomIndex == mapResConfig.LoadingBG.Length)
                    var loadingBackGroudConfig = Config.Instance.Get<LoadingBackGroundConfig>(mapResConfig.DataID);
                    if (loadingBackGroudConfig != null && loadingBackGroudConfig.icons.Length > 0)
                    {
                        m_BackGround.SetSprite(GeneralDefine.LoadLV);
                        m_ContainerFunctions.gameObject.SetActive(true);
                        var functions = GetShowFunctions(PlayerDatas.Instance.baseData.LV == 0 ? PlayerDatas.Instance.loginInfo.LV : PlayerDatas.Instance.baseData.LV);
                        for (int i = 0; i < m_FunctionShows.Length; i++)
                        var icons = new List<string>();
                        var json = JsonMapper.ToObject(loadingBackGroudConfig.levelLimit);
                        for (var i = 0; i < loadingBackGroudConfig.icons.Length; i++)
                        {
                            var show = m_FunctionShows[i];
                            show.Display(functions[i]);
                            var icon = loadingBackGroudConfig.icons[i];
                            if (json.Keys.Contains(icon))
                            {
                                var min = 0;
                                var max = int.MaxValue;
                                var levelLimit = json[icon].ToString();
                                var levelsMatch = Regex.Matches(levelLimit, "\\d+");
                                if (levelsMatch.Count > 0)
                                {
                                    min = int.Parse(levelsMatch[0].Value);
                                }
                                if (levelsMatch.Count > 1)
                                {
                                    max = int.Parse(levelsMatch[1].Value);
                                }
                                if (playerLevel > min && playerLevel < max)
                                {
                                    icons.Add(icon);
                                }
                            }
                            else
                            {
                                icons.Add(icon);
                            }
                        }
                    }
                    else
                    {
                        m_BackGround.SetSprite(mapResConfig.LoadingBG[randomIndex]);
                        m_ContainerFunctions.gameObject.SetActive(false);
                    }
                }
                if (mapResConfig != null && !string.IsNullOrEmpty(mapResConfig.LoadName))
                {
                    m_ContainerMapName.gameObject.SetActive(true);
                    m_MapName.SetSprite(mapResConfig.LoadName);
                }
                else
                {
                    m_ContainerMapName.gameObject.SetActive(false);
                }
                        var randomIndex = UnityEngine.Random.Range(0, loadingBackGroudConfig.icons.Length > 1 ? icons.Count + 1 : 1);
                        if (randomIndex == icons.Count)
                        {
                            m_BackGround.SetSprite(GeneralDefine.LoadLV);
                            m_ContainerFunctions.gameObject.SetActive(true);
                            var functions = GetShowFunctions(playerLevel);
                            for (int i = 0; i < m_FunctionShows.Length; i++)
                            {
                                var show = m_FunctionShows[i];
                                show.Display(functions[i]);
                            }
                        }
                        else
                        {
                            m_BackGround.SetSprite(icons[randomIndex]);
                            m_ContainerFunctions.gameObject.SetActive(false);
                        }
                if (mapResConfig != null && !string.IsNullOrEmpty(mapResConfig.LoadDescription))
                {
                    m_ContainerMapDescription.gameObject.SetActive(true);
                    m_MapDescription.SetSprite(mapResConfig.LoadDescription);
                }
                else
                {
                    m_ContainerMapDescription.gameObject.SetActive(false);
                        if (loadingBackGroudConfig != null && !string.IsNullOrEmpty(loadingBackGroudConfig.name))
                        {
                            m_ContainerMapName.gameObject.SetActive(true);
                            m_MapName.SetSprite(loadingBackGroudConfig.name);
                        }
                        else
                        {
                            m_ContainerMapName.gameObject.SetActive(false);
                        }
                        if (loadingBackGroudConfig != null && !string.IsNullOrEmpty(loadingBackGroudConfig.description))
                        {
                            m_ContainerMapDescription.gameObject.SetActive(true);
                            m_MapDescription.SetSprite(loadingBackGroudConfig.description);
                        }
                        else
                        {
                            m_ContainerMapDescription.gameObject.SetActive(false);
                        }
                    }
                }
            }
            if (Application.platform == RuntimePlatform.IPhonePlayer)
            {
System/WindowBase/ModelCenter.cs
@@ -207,6 +207,7 @@
            RegisterModel<ChatBubbleModel>();
            RegisterModel<AccumulateRechargeModel>();
            RegisterModel<FBHelpPointExchageModel>();
            RegisterModel<IceCrystalVeinModel>();
            inited = true;
        }