コード例 #1
0
        public void StartDeadlineTimer()
        {
            if (DeadLineTimer != null)
            {
                DeadLineTimer.Stop();
            }

            DeadLineTimer = Timer.DelayCall(TimeSpan.FromSeconds(1), TimeSpan.FromSeconds(1), CheckDeadLine);
            DeadLineTimer.Start();
        }
コード例 #2
0
        public void EndDeadLineTimer()
        {
            if (DeadLineTimer != null)
            {
                DeadLineTimer.Stop();
                DeadLineTimer = null;
            }

            if (Guardian != null && Guardian.Alive) // Failed
            {
                Guardian.Delete();

                if (Summoner != null)
                {
                    Summoner.SendLocalizedMessage(1151628); // You failed to defeat the champion in time.
                }
                NextSummon = DateTime.UtcNow;
            }
        }