Example #1
0
 public void Check(TimeStat Time)
 {
     if (Points == 0)
     {
         if (handler == null)
         {
             UIControls.Win = new NavigationWindow();
             handler        = new DisplayHandler(CheckLoseEvent);
             resultObj      = handler.BeginInvoke(Time, new AsyncCallback(AsyncCompleted), null);
         }
     }
 }
Example #2
0
        void CheckLoseEvent(TimeStat Time)
        {
            TimeStat loseday = new TimeStat(Time);

            loseday.AddDate(Settings_.daysDied);
            System.Windows.MessageBox.Show(Settings_.warningMessege);
            while (true)
            {
                if (Points > 0)
                {
                    handler = null;
                    flag    = false;
                    return;
                }
                else if (loseday.Is(Time))
                {
                    System.Windows.MessageBox.Show(DiedMessege);
                    flag = true;
                    return;
                }
            }
        }
Example #3
0
 public void AddDate(TimeStat TimeStat)
 {
     Years += TimeStat.Years;
     Days  += TimeStat.Days;
 }
Example #4
0
 public TimeStat(TimeStat TimeStat)
 {
     Years = TimeStat.Years;
     Days  = TimeStat.Days;
 }