少年修仙传客户端代码仓库
client_Wu Xijin
2019-04-12 5c6d49f48e70fd37919e948468a1c24d5aa2990e
System/CrossServerOneVsOne/CrossServerOneVsOneModel.cs
@@ -73,9 +73,11 @@
        public void OnSwitchAccount()
        {
            IsMatching = false;
            if (clientMatchClock!=null )
            if (clientMatchClock != null)
            {
                clientMatchClock.Stop();
                Clock.Stop(clientMatchClock);
                clientMatchClock = null;
            }
        }
@@ -470,7 +472,7 @@
                    var onMatchPackage = new HC002_tagGCCrossRealmPKStartMatch();
                    GameNetSystem.Instance.PushPackage(onMatchPackage, ServerType.Main);
                    var randomWaitSeconds = UnityEngine.Random.Range(3, 8);
                    clientMatchClock = Clock.Create(DateTime.Now + new TimeSpan(randomWaitSeconds * TimeSpan.TicksPerSecond), () =>
                    clientMatchClock = Clock.AlarmAt(DateTime.Now + new TimeSpan(randomWaitSeconds * TimeSpan.TicksPerSecond), () =>
                    {
                        IsMatching = false;
                        if (GameNetSystem.Instance.netState == GameNetSystem.NetState.Connected)
@@ -489,9 +491,10 @@
            }
            else
            {
                if (clientMatchClock != null && !clientMatchClock.stopped)
                if (clientMatchClock != null )
                {
                    clientMatchClock.Stop();
                    Clock.Stop(clientMatchClock);
                    clientMatchClock = null;
                    IsMatching = false;
                }
                else
@@ -506,7 +509,7 @@
        public void SendBuyMatchCount()
        {
            CC102_tagCMCrossRealmPKBuy pKBuy = new CC102_tagCMCrossRealmPKBuy();
            var pKBuy = new CC102_tagCMCrossRealmPKBuy();
            GameNetSystem.Instance.SendInfo(pKBuy);
        }