少年修仙传客户端代码仓库
client_Hale
2019-04-25 f6e402a2ab727b523177a7c759fbee4043ed4168
Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
12个文件已修改
154 ■■■■■ 已修改文件
Fight/Stage/Dungeon/AdventureStage.cs 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Fight/Stage/Dungeon/DungeonStage.cs 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Lua/Gen/SnxxzUIEquipStarModelWrap.cs 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/EquipStar/EquipStar.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/EquipStar/EquipStarLevelSelectBehaviour.cs 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/EquipStar/EquipStarModel.cs 24 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/EquipStar/EquipStarUpgradeCandidateSlot.cs 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/HumanTreasureTaskCell.cs 33 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/HumanTreasureWin.cs 25 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/TreasureCollectBriefInfoBehaviour.cs 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/TreasureModel.cs 35 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Treasure/TreasureNewGotWin.cs 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Fight/Stage/Dungeon/AdventureStage.cs
@@ -63,6 +63,7 @@
    {
        m_Npc = GAMgr.Instance.ReqClntNoFightNpc<GA_NpcClientFunc>((uint)hazyRegionModel.GetAdventureNpcId(), E_ActorGroup.FuncNpc);
        m_Npc.Pos = new Vector3(9.012f, 18.76f, 9.089f);
        m_Npc.Rotation = Quaternion.Euler(0f, 165f, 0f);
        NPCInteractProcessor.s_NpcInteractEvent -= OnNpcTalkEvent;
        NPCInteractProcessor.s_NpcInteractEvent += OnNpcTalkEvent;
    }
Fight/Stage/Dungeon/DungeonStage.cs
@@ -260,6 +260,7 @@
            case HazyGrassModel.Client_ReikiGrassMapID:
            case HazyGrassModel.FairyGrassMapId:
            case HazyGrassModel.ReikiGrassMapId:
                WindowCenter.Instance.Close<DungeonEndCoolDownWin>();
                WindowCenter.Instance.Open<DungeonCollectItemSuccWin>();
                break;
            default:
Lua/Gen/SnxxzUIEquipStarModelWrap.cs
@@ -388,13 +388,6 @@
            
                
                {
                    int _index = LuaAPI.xlua_tointeger(L, 2);
                        Snxxz.UI.EquipStarUpgradeCandidate gen_ret = gen_to_be_invoked.GetCandidatePlace( _index );
                        translator.Push(L, gen_ret);
                    return 1;
                }
                
System/EquipStar/EquipStar.cs
@@ -17,9 +17,9 @@
            this.level = level;
            this.redpoint = new Redpoint(1720000, 1720000 + level * 100);
            for (var i = 1; i <= 12; i++)
            for (var place = 1; place <= 12; place++)
            {
                equipStarPoints[i] = new Redpoint(1720000 + level * 100, 1720000 + level * 100 + i);
                equipStarPoints[place] = new Redpoint(1720000 + level * 100, 1720000 + level * 100 + place);
            }
        }
System/EquipStar/EquipStarLevelSelectBehaviour.cs
@@ -46,10 +46,12 @@
        public void Display()
        {
            var siblingIndex = this.transform.GetSiblingIndex();
            for (var i = 12; i >=1; i--)
            var candidates = this.model.candidatePlaces.Fetch();
            for (var i = candidates.Count - 1; i >= 0; i--)
            {
                var behaviour = EquipStarUpgradeCandidateSlotPool.Get();
                behaviour.Display(i);
                behaviour.Display(candidates[i]);
                behaviour.transform.SetParentEx(this.transform.parent, Vector3.zero, Quaternion.identity, Vector3.one);
                behaviour.transform.SetSiblingIndex(siblingIndex + 1);
                slotBehaviours.Add(behaviour);
System/EquipStar/EquipStarModel.cs
@@ -14,6 +14,7 @@
        public readonly LogicInt equipMaxStarLevel = new LogicInt();
        public readonly LogicInt operateMaterialIndex = new LogicInt();
        public readonly LogicInt starUpgradeProbability = new LogicInt();
        public readonly LogicList<EquipStarUpgradeCandidate> candidatePlaces = new LogicList<EquipStarUpgradeCandidate>();
        public readonly Dictionary<int, LogicString> materials = new Dictionary<int, LogicString>() {
            {1,new LogicString () },
            {2,new LogicString () },
@@ -28,7 +29,7 @@
        public readonly LogicInt starResultEffect = new LogicInt();
        Dictionary<int, EquipSetStar> equipStars = new Dictionary<int, EquipSetStar>();
        List<EquipStarUpgradeCandidate> candidatePlaces = new List<EquipStarUpgradeCandidate>();
        Redpoint redpoint = new Redpoint(1720000);
        bool redpointDirty = false;
@@ -80,10 +81,13 @@
            var maxStarLevel = GetMaxStarLevel(selectedLevel.value);
            UpdateSelelctedEquipStars(selectedEquipOldStar, starLevel, maxStarLevel);
            foreach (var candidate in candidatePlaces)
            for (int i = 0; i < candidatePlaces.Count; i++)
            {
                var candidate = candidatePlaces[i];
                candidate.starLevel.value = GetEquipStarLevel(candidate.equipPosition);
            }
            redpointDirty = true;
        }
        void OnGetUpgradeStarResult(H0721_tagMakeItemAnswer info)
@@ -263,8 +267,9 @@
            selectedPlace.dirty = true;
            if (equipPosition.x > 0 && equipPosition.y >= 1 && equipPosition.y <= 12)
            {
                foreach (var candidate in candidatePlaces)
                for (int i = 0; i < candidatePlaces.Count; i++)
                {
                    var candidate = candidatePlaces[i];
                    candidate.selected.value = candidate.equipPosition == equipPosition;
                }
@@ -277,11 +282,6 @@
                AutoAddMaterials(equipPosition);
                CalculateStarUpgradeProbability(equipPosition);
            }
        }
        public EquipStarUpgradeCandidate GetCandidatePlace(int index)
        {
            return candidatePlaces.Find(x => { return x.equipPosition.y == index; });
        }
        public bool IsEquipPlaceUpgradable(string equipGuid)
@@ -432,7 +432,7 @@
            {
                qualitys = new List<int>(config.CostEquipColor),
                equipTypes = new List<int>(config.CostEquipPlace),
                realmLimit = equip.config.RealmLimit,
                levels = new List<int>() { equip.config.LV }
            });
            for (var i = 1; i <= 5; i++)
@@ -633,7 +633,7 @@
                    }
                    //不是候选者中星级最小的
                    if (starLevel > minStarLevel)
                    if (targetEquipPosition != Int2.zero && starLevel >= minStarLevel)
                    {
                        continue;
                    }
@@ -654,7 +654,7 @@
                    {
                        qualitys = new List<int>(config.CostEquipColor),
                        equipTypes = new List<int>(config.CostEquipPlace),
                        realmLimit = item.config.RealmLimit,
                        levels = new List<int>() { item.config.LV }
                    });
                    for (int j = materials.Count - 1; j >= 0; j--)
@@ -712,7 +712,7 @@
            if (string.IsNullOrEmpty(guidX) && !string.IsNullOrEmpty(guidY))
            {
                return -1;
                return 1;
            }
            if (string.IsNullOrEmpty(guidX) && string.IsNullOrEmpty(guidY))
System/EquipStar/EquipStarUpgradeCandidateSlot.cs
@@ -24,13 +24,11 @@
        EquipModel equipModel { get { return ModelCenter.Instance.GetModel<EquipModel>(); } }
        PackModel packModel { get { return ModelCenter.Instance.GetModel<PackModel>(); } }
        int place;
        EquipStarUpgradeCandidate candidate;
        public void Display(int place)
        public void Display(EquipStarUpgradeCandidate candidate)
        {
            this.place = place;
            this.candidate = model.GetCandidatePlace(this.place);
            this.candidate = candidate;
            this.m_Redpoint.redpointId = 1720000 + this.candidate.equipPosition.x * 100 + this.candidate.equipPosition.y;
            DisplayBaseInfo();
            DisplayDynamicInfo(true);
System/Treasure/HumanTreasureTaskCell.cs
@@ -46,38 +46,7 @@
            var taskConfig = TaskListConfig.Get(tasks[0]);
            m_ClueName.text = taskConfig.clueName;
            var clueState = 0;
            Treasure treasure;
            var taskId = taskModel.GetLatestMainTaskId();
            var taskState = taskModel.GetQuestState(taskId);
            if (model.TryGetTreasure(model.selectedTreasure, out treasure))
            {
                if (treasure.state == TreasureState.Collected)
                {
                    clueState = 2;
                }
                else
                {
                    var lastTask = tasks[tasks.Count - 1];
                    if (taskId > lastTask || (taskId == lastTask && taskState == 3))
                    {
                        clueState = 2;
                    }
                    else
                    {
                        if (tasks.Contains(taskId))
                        {
                            clueState = 1;
                        }
                        else
                        {
                            clueState = 0;
                        }
                    }
                }
            }
            var clueState = model.GetClueState(model.selectedTreasure, clue);
            m_ContainerCollected.gameObject.SetActive(clueState == 2);
            m_ContainerCollecting.gameObject.SetActive(clueState == 1);
System/Treasure/HumanTreasureWin.cs
@@ -57,6 +57,7 @@
        protected override void BindController()
        {
            m_TaskController.lockType = EnhanceLockType.KeepVertical;
        }
        protected override void AddListeners()
@@ -72,8 +73,6 @@
        {
            m_ContainerSkillDetial.gameObject.SetActive(false);
            Display();
            animationStep = false;
            TreasureBaseWin.allowSelectTreasure += AllowSelectTreasure;
@@ -84,6 +83,7 @@
        protected override void OnActived()
        {
            base.OnActived();
            Display();
            DisplayAnimation();
        }
@@ -171,6 +171,9 @@
            displayTime = 0f;
            var index = -1;
            var jumpIndex = -1;
            m_TaskController.Refresh();
            Dictionary<int, List<int>> clues;
            if (model.TryGetTreasureClues(model.selectedTreasure, out clues))
@@ -191,40 +194,54 @@
                            break;
                    }
                    var clueState = model.GetClueState(model.selectedTreasure, clue);
                    if (display)
                    {
                        if (taskAnimation)
                        {
                            if (inductionTaskId < tasks[tasks.Count - 1])
                            if (model.displayInductionId < tasks[tasks.Count - 1])
                            {
                                animationClues.Add(clue);
                            }
                        }
                        index++;
                        m_TaskController.AddCell(ScrollerDataType.Header, clue);
                        lastClue = clue;
                        if (clueState == 1 && jumpIndex != -1)
                        {
                            jumpIndex = index;
                        }
                    }
                }
                HumanTreasureTaskCell.lastClue = lastClue;
                if (inductionState == 0)
                {
                    index++;
                    HumanTreasureTaskCell.lastClue = -1;
                    m_TaskController.AddCell(ScrollerDataType.Normal, inductionTaskId);
                    jumpIndex = index;
                }
            }
            m_TaskController.Restart();
            animationClues.Clear();
            if (taskAnimation)
            {
                Clock.AlarmAfter(Mathf.CeilToInt(displayTime + 0.6f), () =>
                {
                    m_TaskController.mScrollRect.enabled = true;
                    animationClues.Clear();
                });
            }
            else
            {
                m_TaskController.mScrollRect.enabled = true;
                if (jumpIndex != -1)
                {
                    m_TaskController.JumpIndex(jumpIndex);
                }
            }
        }
System/Treasure/TreasureCollectBriefInfoBehaviour.cs
@@ -120,7 +120,7 @@
        IEnumerator Co_StopEffect()
        {
            yield return WaitingForSecondConst.WaitMS1500;
            yield return WaitingForSecondConst.WaitMS800;
            m_ProgressEffect.StopImediatly();
            DisplayProgress(true);
        }
@@ -181,7 +181,7 @@
                    m_TaskSlider.ResetValue(progress);
                }
                var satisfyChallenge = model.SatisfyChallenge(displayId) && m_TaskSlider.slider.value >= 1f;
                var satisfyChallenge = model.SatisfyChallenge(displayId) && fullProgress;
                m_ContainerChallenge.gameObject.SetActive(satisfyChallenge);
                m_ContainerCollecting.gameObject.SetActive(!satisfyChallenge);
@@ -259,7 +259,7 @@
                DisplayBase();
            }
            fullProgress = m_TaskSlider.slider.value >= 1f;
            fullProgress = m_TaskSlider.slider.value >= 0.98f;
        }
        public void Dispose()
System/Treasure/TreasureModel.cs
@@ -146,6 +146,8 @@
        public int treasureChapterId { get; set; }
        public int displayInductionId { get; private set; }
        TaskModel taskModel { get { return ModelCenter.Instance.GetModel<TaskModel>(); } }
        VIPKillNPCTreasure m_VIPKillNPCTreasure;
@@ -1010,6 +1012,7 @@
                    {
                        if (onInductionTaskComplete != null)
                        {
                            displayInductionId = (int)package.MissionID;
                            onInductionTaskComplete(id);
                        }
                        break;
@@ -1056,6 +1059,38 @@
            return 1;
        }
        public int GetClueState(int treasureId,int clue)
        {
            var treasure = treasures[treasureId];
            if (treasure.state == TreasureState.Collected)
            {
                return 2;
            }
            else
            {
                var taskId = taskModel.GetLatestMainTaskId();
                var taskState = taskModel.GetQuestState(taskId);
                Dictionary<int, List<int>> clues;
                if(TryGetTreasureClues(treasureId, out clues))
                {
                    var tasks = clues[clue];
                    var lastTask = tasks[tasks.Count - 1];
                    if (taskId > lastTask || (taskId == lastTask && taskState == 3))
                    {
                        return 2;
                    }
                    else
                    {
                        if (tasks.Contains(taskId))
                        {
                            return 1;
                        }
                    }
                }
            }
            return 0;
        }
        void TryShowTreasureChapter(int taskId)
        {
            var configs = TreasureChapterConfig.GetValues();
System/Treasure/TreasureNewGotWin.cs
@@ -330,7 +330,8 @@
            var instance = UIUtility.CreateWidget("TreasureUnlockFlyObject_1", "TreasureUnlockFlyObject_1");
            unlockFlyObject1 = instance.GetComponent<FunctionUnlockFlyObject>();
            Transform parent = (treasureStage != null && treasureStage.unlockType == TreasureStageUnlock.Skill) && treasure.id != 101
            Transform parent = (treasureStage != null && treasureStage.unlockType == TreasureStageUnlock.Skill)
                && (TreasureCategory)config.Category != TreasureCategory.Human
                && (TreasureCategory)config.Category != TreasureCategory.Fairy ? m_TreasureExhibitionPoint : m_FlyObjectPoint1;
            unlockFlyObject1.transform.SetParentEx(parent, Vector3.zero, Vector3.zero, Vector3.one);
            unlockFlyObject1.SetContent(FunctionUnlockType.Treasure, treasure.id);
@@ -367,7 +368,8 @@
            if (treasureStage != null && (TreasureCategory)config.Category != TreasureCategory.Fairy
                && treasureStage.unlockType == TreasureStageUnlock.Skill && treasure.id != 101)
                && (TreasureCategory)config.Category != TreasureCategory.Human
                && treasureStage.unlockType == TreasureStageUnlock.Skill)
            {
                var instance2 = UIUtility.CreateWidget("TreasureUnlockFlyObject_2", "TreasureUnlockFlyObject_2");
                unlockFlyObject2 = instance2.GetComponent<FunctionUnlockFlyObject>();