少年修仙传客户端代码仓库
10349 【越南】【英文】【BT】【砍树】跨服竞技场优化  - 跨服排位赛
16个文件已修改
4个文件已删除
605 ■■■■■ 已修改文件
Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0431_tagTimeTick.cs 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/Protocol/DTCFile/ServerPack/HC0_CrossRealm/IL_DTCC016_tagGCCrossChampionshipPKOver.cs 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/Protocol/DTCFile/ServerPack/HC0_CrossRealm/IL_DTCC016_tagGCCrossChampionshipPKOver.cs.meta 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/Protocol/ILPackageRegedit.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/Protocol/ServerPack/HC0_CrossRealm/IL_HC016_tagGCCrossChampionshipPKOver.cs 35 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/Protocol/ServerPack/HC0_CrossRealm/IL_HC016_tagGCCrossChampionshipPKOver.cs.meta 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/System/CrossServerQualifying/CrossServerQualifying64Win.cs 118 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/System/CrossServerQualifying/CrossServerQualifying8Win.cs 113 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/System/CrossServerQualifying/CrossServerQualifyingModel.cs 204 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/System/CrossServerQualifying/CrossServerQualifyingRaceCell.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/System/CrossServerQualifying/CrossServerQualifyingSettlementWin.cs 44 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/System/CrossServerQualifying/CrossServerQualifyingTimeCell.cs 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/System/CrossServerQualifying/ILCrossServerModel.cs 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LogicProject/System/PlayerCommon/HeroControler.cs 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/CrossServerOneVsOne/CrossServerOneVsOneModel.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/CrossServerOneVsOne/FightingPKWin.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/DailyQuest/ActivityPlaceWin.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Dungeon/DungeonModel.cs 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/GeneralConfig/GeneralDefine.cs 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Login/CrossServerLogin.cs 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0431_tagTimeTick.cs
@@ -28,11 +28,7 @@
                    break;
                case CrossServerOneVsOneModel.CrossServerDataMapId:
                case ClientCrossServerOneVsOne.mapId:
                    if (!WindowCenter.Instance.IsOpen<BattlePrepareCoolDownWin>())
                    {
                        WindowCenter.Instance.Open<BattlePrepareCoolDownWin>();
                    }
                    break;
                case CrossServerQualifyingModel.DATA_MAPID:
                case ArenaManager.MapID:
                    if (!WindowCenter.Instance.IsOpen<BattlePrepareCoolDownWin>())
                    {
@@ -44,9 +40,8 @@
        switch (mapId)
        {
            case CrossServerOneVsOneModel.CrossServerDataMapId:
                WindowCenter.Instance.Close<DungeonEndCoolDownWin>();
                WindowCenter.Instance.Close<DungeonBeginCoolDownWin>();
                break;
            case ClientCrossServerOneVsOne.mapId:
            case CrossServerQualifyingModel.DATA_MAPID:
            case ArenaManager.MapID:
                WindowCenter.Instance.Close<DungeonEndCoolDownWin>();
                WindowCenter.Instance.Close<DungeonBeginCoolDownWin>();
LogicProject/Protocol/DTCFile/ServerPack/HC0_CrossRealm/IL_DTCC016_tagGCCrossChampionshipPKOver.cs
File was deleted
LogicProject/Protocol/DTCFile/ServerPack/HC0_CrossRealm/IL_DTCC016_tagGCCrossChampionshipPKOver.cs.meta
File was deleted
LogicProject/Protocol/ILPackageRegedit.cs
@@ -80,7 +80,7 @@
        //跨服排位赛
        Register(typeof(HC015_tagGCCrossChampionshipPKZoneGroupInfo), typeof(DTCC015_tagGCCrossChampionshipPKZoneGroupInfo));
        Register(typeof(IL_HC016_tagGCCrossChampionshipPKOver), typeof(IL_DTCC016_tagGCCrossChampionshipPKOver));
        //Register(typeof(IL_HC016_tagGCCrossChampionshipPKOver), typeof(IL_DTCC016_tagGCCrossChampionshipPKOver));
        Register(typeof(IL_HC022_tagGCChampionshipGuessPubInfo), typeof(IL_DTCC022_tagGCChampionshipGuessPubInfo));
        Register(typeof(IL_HC023_tagGCChampionshipGuessPriInfo), typeof(IL_DTCC023_tagGCChampionshipGuessPriInfo));
        Register(typeof(HC018_tagGCChampionshipOfficialInfo), typeof(DTCC018_tagGCChampionshipOfficialInfo));
LogicProject/Protocol/ServerPack/HC0_CrossRealm/IL_HC016_tagGCCrossChampionshipPKOver.cs
File was deleted
LogicProject/Protocol/ServerPack/HC0_CrossRealm/IL_HC016_tagGCCrossChampionshipPKOver.cs.meta
File was deleted
LogicProject/System/CrossServerQualifying/CrossServerQualifying64Win.cs
@@ -17,13 +17,22 @@
    Button btn16;
    List<Image> selectImgs = new List<Image>();
    Button timeBtn;
    ButtonEx enterGame;
    ScrollerController scroller;
    Text timeTip;   //显示自己当前进场信息和小窗推送配合
    Button guessBtn;
    Image lineImg;
    Text waitTxt;
    Image arrow;
    ButtonEx enterGame;
    Text pkResultText;
    RectTransform pkTagetObjs; //有比赛场次的时候显示
    Text timeTip;   //显示自己当前进场信息和小窗推送配合
    Text pkTimesText;
    Text pkScoreText;
    RectTransform tagPlayerObj;
    RectTransform todayRaceObj;
    Text todayRaceText;
    Button littleCloseBtn;
    
@@ -47,6 +56,16 @@
        lineImg = proxy.GetWidgtEx<Image>("line");
        guessBtn = proxy.GetWidgtEx<Button>("guessBtn");
        arrow = proxy.GetWidgtEx<Image>("arrow");
        pkResultText = proxy.GetWidgtEx<Text>("pkResult");
        pkTagetObjs = proxy.GetWidgtEx<RectTransform>("chanllenge");
        pkTimesText = proxy.GetWidgtEx<Text>("challengeTimes");
        pkScoreText = proxy.GetWidgtEx<Text>("score");
        tagPlayerObj = proxy.GetWidgtEx<RectTransform>("tagetPlayer");
        todayRaceObj = proxy.GetWidgtEx<RectTransform>("raceTip");
        todayRaceText = proxy.GetWidgtEx<Text>("todayrace");
        littleCloseBtn = proxy.GetWidgtEx<Button>("littleClose");
    }
    protected override void AddListeners()
@@ -78,6 +97,11 @@
            arrow.SetActiveIL(false);
            WindowCenter.Instance.OpenIL<CrossServerQualifyingGuess8Win>();
        });
        littleCloseBtn.SetListener(()=>{
            CrossServerQualifyingModel.Instance.isShowRaceInfoYet = true;
            todayRaceObj.SetActive(!CrossServerQualifyingModel.Instance.isShowRaceInfoYet);
        });
    }
    protected override void OnPreOpen()
@@ -97,6 +121,11 @@
        {
            arrow.SetActiveIL(ILChampionshipTimeConfig.Get(battleID).StateValue == 80);
        }
        //顶部晋级信息显示
        var nextBattle = CrossServerQualifyingModel.Instance.GetMyNextBattle();
        pkResultText.SetActive(nextBattle != 0);
        pkResultText.text = Language.Get("CrossServerQualifying71", nextBattle);
    }
@@ -211,25 +240,92 @@
    void OnMinuteEvent()
    {
        var groupMark = CrossServerQualifyingModel.Instance.nowGroupMark;
        enterGame.SetActiveIL(false);
        pkTagetObjs.SetActiveIL(false);
        todayRaceObj.SetActiveIL(false);
        timeTip.text = string.Empty;
        var findIndex = CrossServerQualifyingModel.Instance.groupBtnMarks.IndexOf(groupMark);
        if (findIndex != -1 && groupMark <= 64 && groupMark >= 16)
        {
            var isInBattle = CrossServerQualifyingModel.Instance.HaveMyBattle(groupMark);
            enterGame.SetActiveIL(isInBattle);
            int battleID = CrossServerQualifyingModel.Instance.GetBattleID();
            if (isInBattle && ILChampionshipTimeConfig.Get(battleID).StateValue % 10 == 2)
            {
                pkTagetObjs.SetActiveIL(true);
                //ItemOverdue104 {0}分
                //ItemTipTime1    剩余时间:
                //OSCActivityNotOpen    活动未开始
                //FamilyMatchAlreadyEnd < color =#109d06>已结束</color>
                double minute = CrossServerQualifyingModel.Instance.GetRaceEndRemindMinute(battleID);
                if (minute >= 0)
                {
                    timeTip.text = StringUtility.Contact(Language.Get("ItemTipTime1"), " ", Language.Get("ItemOverdue104", (int)minute));
                }
                else
                {
                    timeTip.text = Language.Get("FamilyMatchAlreadyEnd");
                }
                ShowBattleInfo(groupMark);
            }
            if (isInBattle)
            {
                var battleID = ILChampionshipTimeConfig.GetBattleID((int)groupMark * 10 + 2);
                if (battleID != 0)
                ShowTodayRaceInfo();
            }
        }
    }
    void ShowBattleInfo(uint groupMark)
                {
                    timeTip.text = Language.Get("CrossServerQualifying20", CrossServerQualifyingModel.Instance.GetStartBattleTime(battleID));
                    return;
                }
            }
        }
        uint tagPlayerID;
        var battleResult = CrossServerQualifyingModel.Instance.GetMyBattleInfo(groupMark, out tagPlayerID);
        int challengeCnt = battleResult.ContainsKey((int)PlayerDatas.Instance.baseData.PlayerID) ? battleResult[(int)PlayerDatas.Instance.baseData.PlayerID].Length : 0;
        //FindPrecious_14    挑战次数:
        pkTimesText.text = StringUtility.Contact(Language.Get("FindPrecious_14"), " ",
            CrossServerQualifyingModel.Instance.challengeMaxCnt - challengeCnt,
            "/", CrossServerQualifyingModel.Instance.challengeMaxCnt);
        
        // 战斗结果明细 {"playerID":[[第1局胜负,第1局总积分,胜负基础分,hp分,时间分], ...], ...}
        int myScore = 0;
        int tagScore = 0;
        var keys = battleResult.Keys.ToList();
        for (int i = 0; i < keys.Count; i++)
        {
            var key = keys[i];
            if (key == (int)PlayerDatas.Instance.baseData.PlayerID)
            {
                for (int j = 0; j < battleResult[key].Length; j++)
                {
                    myScore += battleResult[key][j][1];
                }
            }
            else
            {
                for (int j = 0; j < battleResult[key].Length; j++)
                {
                    tagScore += battleResult[key][j][1];
                }
            }
        }
        //L2033    比分:
        pkScoreText.text = StringUtility.Contact( Language.Get("L2033"), " ", myScore, " - ", tagScore);
        var _cell = tagPlayerObj.GetILBehaviour<CSQShootOutPlayerCell>();
        _cell.Display(tagPlayerID, 0);
    }
    void ShowTodayRaceInfo()
    {
        todayRaceObj.SetActiveIL(!CrossServerQualifyingModel.Instance.isShowRaceInfoYet);
        string raceInfo = StringUtility.Contact(Language.Get("CrossServerQualifying70"), "</r>");
        foreach (int mark in CrossServerQualifyingModel.Instance.groupBtnMarks)
        {
            int tmpBattleID = ILChampionshipTimeConfig.GetBattleID(mark * 10 + 2);
            var tmpConfig = ILChampionshipTimeConfig.Get(tmpBattleID);
            raceInfo = StringUtility.Contact(raceInfo, "</r>", tmpConfig.Title, "    ",
                tmpConfig.StartHour.ToString("D2"), ":", tmpConfig.StartMinute.ToString("D2"), " - ",
                tmpConfig.EndHour.ToString("D2"), ":", tmpConfig.EndMinute.ToString("D2"));
        }
        todayRaceText.text = raceInfo;
    }
    void UpdateRace()
LogicProject/System/CrossServerQualifying/CrossServerQualifying8Win.cs
@@ -14,9 +14,7 @@
{
    Transform raceTable;
    Text waitTxt;
    Text timeTip;   //显示自己当前进场信息和小窗推送配合
    Button raceBtn;
    ButtonEx enterGame;
    Button giftBtn;
    Button guessBtn;
    Text time1;
@@ -35,6 +33,15 @@
    Image arrow;
    Text nextTime;
    ButtonEx enterGame;
    RectTransform pkTagetObjs; //有比赛场次的时候显示
    Text timeTip;   //显示自己当前进场信息和小窗推送配合
    Text pkTimesText;
    Text pkScoreText;
    RectTransform tagPlayerObj;
    RectTransform todayRaceObj;
    Text todayRaceText;
    Button littleCloseBtn;
    #region Built-in
    protected override void BindController()
@@ -70,6 +77,14 @@
        fightPowerB = proxy.GetWidgtEx<Text>("fightPowerB");
        arrow = proxy.GetWidgtEx<Image>("arrow");
        nextTime = proxy.GetWidgtEx<Text>("nextTime");
        pkTagetObjs = proxy.GetWidgtEx<RectTransform>("chanllenge");
        pkTimesText = proxy.GetWidgtEx<Text>("challengeTimes");
        pkScoreText = proxy.GetWidgtEx<Text>("score");
        tagPlayerObj = proxy.GetWidgtEx<RectTransform>("tagetPlayer");
        todayRaceObj = proxy.GetWidgtEx<RectTransform>("raceTip");
        todayRaceText = proxy.GetWidgtEx<Text>("todayrace");
        littleCloseBtn = proxy.GetWidgtEx<Button>("littleClose");
    }
    protected override void AddListeners()
@@ -88,6 +103,11 @@
        giftBtn.SetListener(() => {
            WindowCenter.Instance.OpenIL<CrossServerQualifyingRankWin>();
        });
        littleCloseBtn.SetListener(() => {
            CrossServerQualifyingModel.Instance.isShowRaceInfoYet = true;
            todayRaceObj.SetActive(!CrossServerQualifyingModel.Instance.isShowRaceInfoYet);
        });
    }
@@ -130,8 +150,8 @@
        }
        else
        {
            enterGame.SetActiveIL(false);
            timeTip.text = string.Empty;
            pkTagetObjs.SetActiveIL(false);
            todayRaceObj.SetActiveIL(false);
            DisplayTime();
            raceTable.SetActiveIL(false);
            waitTxt.SetActiveIL(true);
@@ -305,26 +325,97 @@
    void OnMinuteEvent()
    {
        enterGame.SetActiveIL(false);
        timeTip.text = string.Empty;
        pkTagetObjs.SetActiveIL(false);
        todayRaceObj.SetActiveIL(false);
        var groupMark = CrossServerQualifyingModel.Instance.nowGroupMark;
        if (groupMark <= 8 && groupMark != 0)
        {
            var isInBattle = CrossServerQualifyingModel.Instance.HaveMyBattle(groupMark);
            //如果玩家界面一直开着就需要刷新
            if (CrossServerQualifyingModel.Instance.HaveMyBattle(groupMark))
            int battleID = CrossServerQualifyingModel.Instance.GetBattleID();
            if (isInBattle && ILChampionshipTimeConfig.Get(battleID).StateValue % 10 == 2)
            {
                enterGame.SetActiveIL(true);
                var battleID = ILChampionshipTimeConfig.GetBattleID((int)groupMark * 10 + 2);
                if (battleID != 0)
                pkTagetObjs.SetActiveIL(true);
                //ItemOverdue104 {0}分
                //ItemTipTime1    剩余时间:
                //OSCActivityNotOpen    活动未开始
                //FamilyMatchAlreadyEnd < color =#109d06>已结束</color>
                double minute = CrossServerQualifyingModel.Instance.GetRaceEndRemindMinute(battleID);
                if (minute >= 0)
                {
                    timeTip.text = Language.Get("CrossServerQualifying20", CrossServerQualifyingModel.Instance.GetStartBattleTime(battleID));
                    timeTip.text = StringUtility.Contact(Language.Get("ItemTipTime1"), " ", Language.Get("ItemOverdue104", (int)minute));
                }
                else
                {
                    timeTip.text = Language.Get("FamilyMatchAlreadyEnd");
                }
                ShowBattleInfo(groupMark);
            }
            if (isInBattle)
            {
                ShowTodayRaceInfo();
            }
        }
    }
    void ShowBattleInfo(uint groupMark)
    {
        uint tagPlayerID;
        var battleResult = CrossServerQualifyingModel.Instance.GetMyBattleInfo(groupMark, out tagPlayerID);
        int challengeCnt = battleResult.ContainsKey((int)PlayerDatas.Instance.baseData.PlayerID) ? battleResult[(int)PlayerDatas.Instance.baseData.PlayerID].Length : 0;
        //FindPrecious_14    挑战次数:
        pkTimesText.text = StringUtility.Contact(Language.Get("FindPrecious_14"), " ",
            CrossServerQualifyingModel.Instance.challengeMaxCnt - challengeCnt,
            "/", CrossServerQualifyingModel.Instance.challengeMaxCnt);
        // 战斗结果明细 {"playerID":[[第1局胜负,第1局总积分,胜负基础分,hp分,时间分], ...], ...}
        int myScore = 0;
        int tagScore = 0;
        var keys = battleResult.Keys.ToList();
        for (int i = 0; i < keys.Count; i++)
        {
            var key = keys[i];
            if (key == (int)PlayerDatas.Instance.baseData.PlayerID)
            {
                for (int j = 0; j < battleResult[key].Length; j++)
                {
                    myScore += battleResult[key][j][1];
                }
            }
            else
            {
                for (int j = 0; j < battleResult[key].Length; j++)
                {
                    tagScore += battleResult[key][j][1];
                }
            }
        }
        //L2033    比分:
        pkScoreText.text = StringUtility.Contact(Language.Get("L2033"), " ", myScore, " - ", tagScore);
        var _cell = tagPlayerObj.GetILBehaviour<CSQShootOutPlayerCell>();
        _cell.Display(tagPlayerID, 0);
    }
    void ShowTodayRaceInfo()
    {
        todayRaceObj.SetActiveIL(!CrossServerQualifyingModel.Instance.isShowRaceInfoYet);
        string raceInfo = StringUtility.Contact(Language.Get("CrossServerQualifying70"), "</r>");
        foreach (int mark in CrossServerQualifyingModel.Instance.group8BtnMarks)
        {
            int tmpBattleID = ILChampionshipTimeConfig.GetBattleID(mark * 10 + 2);
            var tmpConfig = ILChampionshipTimeConfig.Get(tmpBattleID);
            raceInfo = StringUtility.Contact(raceInfo, "</r>", tmpConfig.Title, "    ",
                tmpConfig.StartHour.ToString("D2"), ":", tmpConfig.StartMinute.ToString("D2"), " - ",
                tmpConfig.EndHour.ToString("D2"), ":", tmpConfig.EndMinute.ToString("D2"));
        }
        todayRaceText.text = raceInfo;
    }
    void UpdateRace()
    {
        if (!raceTable.gameObject.activeSelf)
LogicProject/System/CrossServerQualifying/CrossServerQualifyingModel.cs
@@ -12,10 +12,10 @@
public class CrossServerQualifyingModel : ILModel<CrossServerQualifyingModel>
{
    public const int DATA_MAPID = 32070;
    List<int> mapList = new List<int>();    //1个分区一个地图
    public int selectIndex; // 跨服排位主标签选择
    public int select64Index = 0;  // 选中的64强比赛标签,非当前赛程
    public List<uint> groupBtnMarks = new List<uint>() { 64, 32, 16 };//64强标签按钮对应的赛程
    public List<uint> group8BtnMarks = new List<uint>() { 8, 4, 2 };//8强
    public uint select64Mark
    {
        get { return groupBtnMarks[select64Index]; }
@@ -89,8 +89,10 @@
    public event Action UpdateWorshipEvent;
    public int worshipMaxCnt;
    public int[][] doubleTimeArr;
    public int challengeMaxCnt; //挑战次数
    DungeonModel dungeonModel { get { return ModelCenter.Instance.GetModel<DungeonModel>(); } }
    ServerMirrorFightModel mirrorFightModel { get { return ModelCenter.Instance.GetModel<ServerMirrorFightModel>(); } }
    protected override void Init()
    {
@@ -115,8 +117,6 @@
        {
            openTimes.Add(Convert.ToDateTime(openTimeArr[i]));
        }
        mapList = JsonMapper.ToObject<int[]>(config.Numerical3).ToList();
        config = FuncConfigConfig.Get("CrossChamGuess");
        var moneyInfo = config.Numerical1.Split('|');
@@ -160,6 +160,9 @@
        config = FuncConfigConfig.Get("CrossChamWorship");
        worshipMaxCnt = int.Parse(config.Numerical1);
        doubleTimeArr = JsonMapper.ToObject<int[][]>(config.Numerical3);
        config = FuncConfigConfig.Get("CrossChamMirrorPK");
        challengeMaxCnt = int.Parse(config.Numerical1);
    }
@@ -252,7 +255,8 @@
                    BattleNum = battleList.BattleNum,
                    WinPlayerID = battleList.WinPlayerID,
                    PlayerIDA = battleList.PlayerIDA,
                    PlayerIDB = battleList.PlayerIDB
                    PlayerIDB = battleList.PlayerIDB,
                    battleResult = ConfigParse.ParseIntArray2Dict(battleList.BattleRet),
                };
            }
        }
@@ -279,6 +283,8 @@
        myOfficialID = 0;
        myApplyCnt = 0;
        worshipCntToday = 0;
        pushGroupMark = 0;
        isShowRaceInfoYet = false;
    }
    //获取当前的比赛赛程节点,-1代表当前时间不在排位赛流程中
@@ -327,6 +333,19 @@
        return startTime.ToString("yyyy-MM-dd HH:mm");
    }
    //获取流程的结束时间 分钟,负数代表未开始
    public double GetRaceEndRemindMinute(int battleID)
    {
        var index = GetOpenTimeIndex();
        if (index == -1) return -1;
        var startDay = openTimes[index];
        var config = ILChampionshipTimeConfig.Get(battleID);
        var endTime = startDay.AddDays(config.StartDay - 1).AddSeconds(config.EndHour * 60 * 60 + config.EndMinute * 60);
        return (endTime - ILTimeUtility.ServerCrossNow).TotalMinutes;
    }
    public struct CrossChampionshipPKPlayer
    {
        public uint PlayerID;     
@@ -345,6 +364,7 @@
        public uint WinPlayerID;        // 获胜玩家ID
        public uint PlayerIDA;        // 玩家IDA
        public uint PlayerIDB;        // 玩家IDB
        public Dictionary<int, int[][]>  battleResult;  // 战斗结果明细 {"playerID":[[第1局胜负,第1局总积分,胜负基础分,hp分,时间分], ...], ...}
    }
    public struct ChampionshipOfficial
@@ -356,57 +376,35 @@
        public List<CrossChampionshipPKPlayer> ApplyPlayerList;        // 申请该仙官玩家列表
    }
    //场景进入逻辑借用了跨服竞技1V1
    public bool IsCrossServerQualifying()
    {
        var dungeonModel = ModelCenter.Instance.GetModel<DungeonModel>();
        var dataMapId = dungeonModel.GetDataMapIdByMapId(PlayerDatas.Instance.baseData.MapID);
        return mapList.IndexOf(dataMapId) != -1;
    }
    //进入跨服排位赛,借用跨服竞技1v1模拟
    public void EnterCrossServerQualifying()
    {
        int error;
        if (!ILCrossServerModel.Instance.CanEnter(out error))
        uint tagPlayerID;
        var battleResult = GetMyBattleInfo(nowGroupMark, out tagPlayerID);
        int challengeCnt = battleResult.ContainsKey((int)PlayerDatas.Instance.baseData.PlayerID) ? battleResult[(int)PlayerDatas.Instance.baseData.PlayerID].Length : 0;
        if (challengeCnt >= challengeMaxCnt)
        {
            ILCrossServerModel.Instance.ProcessEnterError(error);
        }
        uint otherPlayerID = 0;
        int pos = 1; //我的位置,1-左;2-右
        var battle = battleInfo[nowGroupMark];
        var battleNums = battle.Keys.ToList();
        var playerID = PlayerDatas.Instance.baseData.PlayerID;
        for (int i = 0; i < battleNums.Count; i++)
        {
            var battleNum = battleNums[i];
            //搜索玩家是否参赛者
            if (battle[battleNum].PlayerIDA == playerID)
            {
                otherPlayerID = battle[battleNum].PlayerIDB;
                pos = 1;
                break;
            }
            else if (battle[battleNum].PlayerIDB == playerID)
            {
                otherPlayerID = battle[battleNum].PlayerIDA;
                pos = 2;
                break;
            }
        }
        if (otherPlayerID == 0)
        {
            //轮空
            SysNotifyMgr.Instance.ShowTip("CrossServerQualifying4");
            SysNotifyMgr.Instance.ShowTip("CrossServerQualifying11");
            return;
        }
        var otherPlayerInfo = fightersInfo[otherPlayerID];
        var package = new HC001_tagGCCrossRealmPKMatchOK();
        //package.RoomID = 1001;
        //package.PlayerName = PlayerDatas.Instance.baseData.PlayerName;
        //package.Number = (byte)pos;
        int error;
        if (!dungeonModel.CanEnter(out error))
        {
            dungeonModel.ProcessEnterError(error);
            return;
        }
        var teamModel = ModelCenter.Instance.GetModel<TeamModel>();
        if (teamModel.isMatching)
        {
            teamModel.RequestCancelAutoMatchTeam();
        }
        var otherPlayerInfo = fightersInfo[tagPlayerID];
        var opponent = new HC001_tagGCCrossRealmPKMatchOK.tagGCCrossRealmPKMatchPlayer();
        opponent.Job = otherPlayerInfo.Job;
@@ -414,20 +412,18 @@
        opponent.PlayerID = otherPlayerInfo.PlayerID;
        opponent.LV = otherPlayerInfo.LV;
        //待进入游戏刷新对方血量
        //opponent.MaxProDef = 100;
        //opponent.MaxHP = 100;
        //opponent.MaxHPEx = 0;
        package.MatchPlayer = new HC001_tagGCCrossRealmPKMatchOK.tagGCCrossRealmPKMatchPlayer[] { opponent };
        opponent.RealmLV = otherPlayerInfo.RealmLV;
        opponent.Face = otherPlayerInfo.Face;
        opponent.FacePic = otherPlayerInfo.FacePic;
        opponent.FightPower = (uint)((ulong)otherPlayerInfo.FightPower % Constants.ExpPointValue);
        opponent.FightPowerEx = (uint)((ulong)otherPlayerInfo.FightPower / Constants.ExpPointValue);
        //var sendInfo = new CC105_tagCMEnterCrossServer();
        //sendInfo.DataMapID = DATA_MAPID;
        //GameNetSystem.Instance.SendInfo(sendInfo);
        CrossServerLogin.Instance.InitOneVsOnePlayerInfo(opponent);
        mirrorFightModel.SendMirrorFight(DATA_MAPID, (ushort)(zoneID * 100 + nowGroupMark), tagPlayerID, 0);
        return;
    }
    //查找自己是否有比赛
    //查找自己是否有比赛,包含竞猜 分组和战斗结束的缓存时间
    public bool HaveMyBattle(uint groupMark)
    {
        if (battleInfo.ContainsKey(groupMark))
@@ -449,24 +445,85 @@
        return false;
    }
    public byte OverType;    // 0-正常,1-有人离线
    public uint WinnerID;    // 胜方ID
    public List<uint> RoundWinnerID = new List<uint>();    // 回合获胜ID列表
    // 8强之前,查找玩家的下一场比赛,胜出未分组前也算
    public int GetMyNextBattle()
    {
        int nextGroupMark = 0;
        bool haveBattle = false;
        for (int k = 0; k < groupBtnMarks.Count; k++)
        {
            var groupMark = groupBtnMarks[k];
            nextGroupMark = (int)groupMark;
            if (battleInfo.ContainsKey(groupMark))
            {
                var playerID = PlayerDatas.Instance.baseData.PlayerID;
                var battle = battleInfo[groupMark];
                var battleNums = battle.Keys.ToList();
                for (int i = 0; i < battleNums.Count; i++)
                {
                    var battleNum = battleNums[i];
                    //搜索玩家是否参赛者
                    if (battle[battleNum].WinPlayerID == playerID)
                    {
                        haveBattle = true;
                        continue;
                    }
                    if (battle[battleNum].PlayerIDA == playerID || battle[battleNum].PlayerIDB == playerID)
                    {
                        haveBattle = true;
                        return nextGroupMark;
                    }
                }
            }
        }
    public void UpdatePKResult(IL_HC016_tagGCCrossChampionshipPKOver netPack)
        return haveBattle ? nextGroupMark : 0;
    }
    //当前的比赛比分情况
    public Dictionary<int, int[][]> GetMyBattleInfo(uint groupMark, out uint tagPlayerID)
    {
        if (IsCrossServerQualifying())//副本结算界面
        tagPlayerID = 0;
        if (battleInfo.ContainsKey(groupMark))
        {
            OverType = netPack.OverType;
            WinnerID = netPack.WinnerID;
            RoundWinnerID = netPack.RoundWinnerID.ToList();
            var playerID = PlayerDatas.Instance.baseData.PlayerID;
            var battle = battleInfo[groupMark];
            var battleNums = battle.Keys.ToList();
            for (int i = 0; i < battleNums.Count; i++)
            {
                var battleNum = battleNums[i];
                if (battle[battleNum].PlayerIDA == playerID || battle[battleNum].PlayerIDB == playerID)
                {
                    tagPlayerID = battle[battleNum].PlayerIDA == playerID ? battle[battleNum].PlayerIDB : battle[battleNum].PlayerIDA;
                    return battle[battleNum].battleResult;
                }
            }
        }
        return null;
    }
    public uint WinnerID;    // 胜方ID
    public int score;
    public void UpdatePKResult()
    {
        if (dungeonModel.dungeonResult.isWin == 1)
        {
            WinnerID = PlayerDatas.Instance.baseData.PlayerID;
        }
        score = dungeonModel.dungeonResult.addScore;
            
            if (WindowCenter.Instance.IsOpen<FightingPKWin>())
            {
                WindowCenter.Instance.Close<FightingPKWin>();
            }
            WindowCenter.Instance.OpenIL<CrossServerQualifyingSettlementWin>();
        }
    }
    
@@ -605,14 +662,23 @@
        return idA.CompareTo(idB);
    }
    public bool isShowRaceInfoYet = false; //是否已经显示过赛程信息小提示
    uint pushGroupMark = 0; //每场比赛只推送一次
    void OnMinuteEvent()
    {
        if (!WindowCenter.Instance.IsOpen("CrossServerQualifyingWin") && mapList.IndexOf(PlayerDatas.Instance.baseData.MapID) == -1)
        if (!WindowCenter.Instance.IsOpen("CrossServerQualifyingWin") &&
            dungeonModel.GetDataMapIdByMapId(PlayerDatas.Instance.baseData.MapID) != DATA_MAPID)
        {
            uint nowMark = nowGroupMark;
            //准备入场的时候推送
            if (GetBattleID() % 10 == 2 && HaveMyBattle(nowGroupMark))
            if (pushGroupMark != nowMark && HaveMyBattle(nowMark))
            {
                int battleID = GetBattleID();
                if (ILChampionshipTimeConfig.Get(battleID).StateValue % 10 == 2)
            { 
                HeroControler.Instance.FuncPush(210);
                    pushGroupMark = nowMark;
                }
            }
        }
    }
LogicProject/System/CrossServerQualifying/CrossServerQualifyingRaceCell.cs
@@ -47,7 +47,9 @@
        var index = CrossServerQualifyingModel.Instance.GetOpenTimeIndex();
        var showTime = CrossServerQualifyingModel.Instance.openTimes[index].AddDays(config.StartDay - 1);
        showTime = showTime.AddSeconds(config.StartHour * 60 * 60 + config.StartMinute * 60);
        timeStr.text = showTime.ToString("yyyy-MM-dd HH:mm");
        timeStr.text = StringUtility.Contact(showTime.ToString("yyyy-MM-dd HH:mm"), " -> ",
                        config.EndHour.ToString("D2"), ":", config.EndMinute.ToString("D2"));
        name.text = Language.Get(raceNameList[listIndex]);
        bg.SetActiveIL(listIndex % 2 == 0);
LogicProject/System/CrossServerQualifying/CrossServerQualifyingSettlementWin.cs
@@ -15,25 +15,23 @@
    Text outTimeText;
    Transform backFail;
    Transform backWin;
    List<Transform> rounds = new List<Transform>();
    List<Text> results = new List<Text>();
    Text resultScore;
    Transform caidaiEffect;
    float timer = 0f;
    int outTime = 5;
    #region Built-in
    DungeonModel model { get { return ModelCenter.Instance.GetModel<DungeonModel>(); } }
    protected override void BindController()
    {
        outBtn = proxy.GetWidgtEx<Button>("DropOutBtn");
        outTimeText = proxy.GetWidgtEx<Text>("DropOutBtn_text");
        backFail = proxy.GetWidgtEx<Transform>("Back_Failure");
        backWin = proxy.GetWidgtEx<Transform>("Back_Win");
        for (int i = 0; i < 3; i++)
        {
            rounds.Add(proxy.GetWidgtEx<Transform>("RoundWin" + i));
            results.Add(proxy.GetWidgtEx<Text>("Text_" + i));
        }
        caidaiEffect = proxy.GetWidgtEx<Transform>("CaidaiEffect");
        resultScore = proxy.GetWidgtEx<Text>("Text_2");
    }
    protected override void AddListeners()
@@ -59,40 +57,14 @@
            backWin.SetActiveIL(false);
            caidaiEffect.SetActiveIL(false);
        }
        for (int i = 0; i < rounds.Count; i++)
        {
            if (i < CrossServerQualifyingModel.Instance.RoundWinnerID.Count)
            {
                rounds[i].SetActiveIL(true);
                if (CrossServerQualifyingModel.Instance.RoundWinnerID[i] == playerID)
                {
                    results[i].text = Language.Get("CrossServer113");
                    results[i].color = new Color32(255, 239, 71, 255);
                }
                else
                {
                    results[i].text = Language.Get("CrossServer114");
                    results[i].color = new Color32(255, 244, 205, 255);
                }
            }
            else
            {
                rounds[i].SetActiveIL(false);
            }
        }
        //如果对方离线,并且一场未打,显示第一回胜利
        if (CrossServerQualifyingModel.Instance.RoundWinnerID.Count == 0 && CrossServerQualifyingModel.Instance.OverType == 1)
        {
            rounds[0].SetActiveIL(true);
            results[0].text = Language.Get("CrossServer113");
            results[0].color = new Color32(255, 239, 71, 255);
        }
        resultScore.text = Language.Get("XMZZ106", CrossServerQualifyingModel.Instance.score);
    }
    protected override void OnPreClose()
    {
        GlobalTimeEvent.Instance.secondEvent -= OnSecondEvent;
        PopupWindowsProcessor.Instance.Add("CrossServerQualifyingWin");
    }
    #endregion
@@ -114,7 +86,7 @@
    private void ExitDungeon()
    {
        WindowCenter.Instance.CloseIL<CrossServerQualifyingSettlementWin>();
        CrossServerOneVsOneRewardModel.ExitCrossRealm();
        model.ExitCurrentDungeon();
    }
}
LogicProject/System/CrossServerQualifying/CrossServerQualifyingTimeCell.cs
@@ -31,7 +31,8 @@
        var index = CrossServerQualifyingModel.Instance.GetOpenTimeIndex();
        var showTime = CrossServerQualifyingModel.Instance.openTimes[index].AddDays(config.StartDay - 1);
        showTime = showTime.AddSeconds(config.StartHour * 60 * 60 + config.StartMinute * 60);
        timeStr.text = showTime.ToString("yyyy-MM-dd HH:mm");
        timeStr.text = StringUtility.Contact(showTime.ToString("yyyy-MM-dd HH:mm"), " -> ",
                        config.EndHour.ToString("D2"), ":", config.EndMinute.ToString("D2"));
        name.text = config.Title;
        desc.text = config.Desc;
LogicProject/System/CrossServerQualifying/ILCrossServerModel.cs
@@ -41,9 +41,6 @@
    void ParseConfig()
    {
        var CrossRealmCfg = FuncConfigConfig.Get("CrossRealmCfg");
        afterOpenDayOpenCrossBattle = int.Parse(CrossRealmCfg.Numerical1);
        var config = FuncConfigConfig.Get("CrossBattlefieldOpen");
        var sysTimes = JsonMapper.ToObject<int[][]>(config.Numerical1);
        for (int i = 0; i < sysTimes.Length; i++)
@@ -278,7 +275,6 @@
    public event Action UpdateBuyInfoEvent;
    public int afterOpenDayOpenCrossBattle;
    //活动开启时间int3 = 时 分 类型(0系统1玩家)
    public List<Int3> crossBattleFieldOpenTimes = new List<Int3>();
    public int processTime; //游戏运行时间(分),此时间也当作游戏进行中和可进入时间,比实际少了准备时间
@@ -341,11 +337,11 @@
    public const int openUIMark = 2080000;
    public int zoneID = 0;
    //同PK一样赛区和赛季总时间,底层c#用到
    //古神战场是否开启
    public bool IsOpen()
    {
        return FuncOpen.Instance.IsFuncOpen(208)
            && TimeUtility.OpenDay >= afterOpenDayOpenCrossBattle
            && TimeUtility.OpenDay >= GeneralDefine.crossServerBattleFieldOpenDay
            //&& CrossServerOneVsOnePKSeason.Instance.InPkSeason(TimeUtility.ServerNow)
            && InOpenTime();
    }
LogicProject/System/PlayerCommon/HeroControler.cs
@@ -80,7 +80,7 @@
    }
    //参考 RoleModel . OnFuncStateChangeEvent  0 未推送 1已推送
    //功能:是否提醒过  1豪华首充 2无限货币 3 在线特惠 4 1元30倍 5 玩法前瞻 6 战场召集 7跨服64排位
    //功能:是否提醒过  1豪华首充 2无限货币 3 在线特惠 4 1元30倍 5 玩法前瞻 6 战场召集 7跨服64排位 8 跨服天梯
    public void FuncPush(int id)
    {
        if (id == 203)
@@ -102,9 +102,17 @@
                roleModel.funcInfo[7] = 0;
            }
        }
        else if (id == 157)
        {
            if (CrossServerOneVsOnePKSeason.Instance.isSatisfyMatch &&
                CrossServerOneVsOnePlayerInfo.Instance.GetDayRemainNum() > 0)
            {
                roleModel.funcInfo[8] = 0;
            }
        }
    }
    List<int> funcPushIDS = new List<int>() { 203, 208, 210 };
    List<int> funcPushIDS = new List<int>() { 157, 208, 210 };
    void OnPlayerLoginOk()
    {
System/CrossServerOneVsOne/CrossServerOneVsOneModel.cs
@@ -131,7 +131,7 @@
                }
            }
            recordDataMapId = dataMapId;
            if (dataMapId == CrossServerDataMapId)
            if (dataMapId == CrossServerDataMapId || dataMapId == CrossServerQualifyingModel.DATA_MAPID)
            {
                PersonalEnemy.OnMirrorPlayerAppear += OnPlayerAppear;
            }
@@ -347,6 +347,7 @@
            var CrossRealmCfg = FuncConfigConfig.Get("CrossRealmCfg");
            afterOpenDayOpenCross = int.Parse(CrossRealmCfg.Numerical1);
            GeneralDefine.crossServerOneVsOneOpenDay = afterOpenDayOpenCross;
        }
        public class AwardType
@@ -720,6 +721,7 @@
            }
        }
        #region 荣誉商店红点
        public const int CrossHonorStoreRedKey = 2130104;
System/CrossServerOneVsOne/FightingPKWin.cs
@@ -623,7 +623,7 @@
        {
            List<int> buffIds = new List<int>();
            _OpponentBuffSortList.Clear();
            StatusMgr.Instance.GetBuffIds((uint)CrossServerLogin.Instance.oneVsOnePlayerData.opponentPlayerId, ref buffIds);
            StatusMgr.Instance.GetBuffIds((uint)CrossServerLogin.Instance.oneVsOnePlayerData.mirrorPlayerID, ref buffIds);
            if (buffIds.Count > 0)
            {
                for (int i = 0; i < buffIds.Count; i++)
System/DailyQuest/ActivityPlaceWin.cs
@@ -349,7 +349,7 @@
            }
            var seconds = (int)(OneTimes - (float)(TimeUtility.ServerNow -
                    System.TimeZone.CurrentTimeZone.ToLocalTime(new DateTime(1970, 1, 1)).AddSeconds(dailyModel.ActivityPlaceInfo.StartTime)).TotalSeconds);
                    TimeUtility.OriginalTime.AddSeconds(dailyModel.ActivityPlaceInfo.StartTime)).TotalSeconds);
            m_DownTime.text = TimeUtility.SecondsToHMS(seconds);
        }
System/Dungeon/DungeonModel.cs
@@ -1449,6 +1449,9 @@
                        case ArenaManager.MapID:
                            ArenaManagerModel.Instance.UpdateFBEnd();
                            break;
                        case CrossServerQualifyingModel.DATA_MAPID:
                            CrossServerQualifyingModel.Instance.UpdatePKResult();
                            break;
                        default:
                            WindowCenter.Instance.Open<DungeonVictoryWin>();
                            break;
System/GeneralConfig/GeneralDefine.cs
@@ -180,7 +180,7 @@
    public static Dictionary<int, Dictionary<int, GA_NpcFightSgzcZZ.EquipRandomInfo>> SgzzRobotEquipDict { get; private set; }
    public static Dictionary<int, int> SgzcRealm { get; private set; }
    public static int crossServerOneVsOneOpenDay { get; private set; }
    public static int crossServerOneVsOneOpenDay { get; set; }
    public static int crossServerBattleFieldOpenDay { get; private set; }
    public static int UISpringDecorate { get; private set; }
    public static Dictionary<int, List<int>> skillAttrIDDict { get; private set; }
@@ -856,7 +856,6 @@
                }
            }
            crossServerOneVsOneOpenDay = GetInt("CrossRealmCfg");
            crossServerBattleFieldOpenDay = GetInt("CrossRealmCfg", 2);
            UISpringDecorate = GetInt("UISpringDecorate");
System/Login/CrossServerLogin.cs
@@ -57,6 +57,7 @@
                opponentLevel = player.LV,
                opponentPlayerId = (int)player.PlayerID,
            };
            LoadingWin.isCrossServerOneVsOne = true;
        }
        public void UpdatePKPlayerInfo(GA_Player player)
@@ -77,6 +78,7 @@
                opponentLevel = oneVsOnePlayerData.opponentLevel,
                opponentPlayerId = oneVsOnePlayerData.opponentPlayerId,
                MaxProDef = (int)player.ActorInfo.maxProDef,
                mirrorPlayerID = (int)player.ServerInstID,
            };
        }
@@ -332,6 +334,7 @@
        public int opponentLevel;
        public ulong opponentMaxHp;
        public int MaxProDef;// 最大护盾
        public int mirrorPlayerID; //镜像玩家ID
        public bool IsCrossServerOneVsOneEntering()