Exemple #1
0
 public DateCounter(TimeSpan timeAdded, IAstroObject tickableObject)
 {
     this.SpeedModiffer  = 1f;
     this.timeAdded      = timeAdded;
     this.tickableObject = tickableObject;
     this.date           = StartingTime; //first we set the backing field
     this.Date           = DateTime.Now; //then we set it again so we can change our object's position
 }
Exemple #2
0
        private TimeSpan timeAdded; //the increase of time every tick

        #endregion Fields

        #region Constructors

        public DateCounter(TimeSpan timeAdded, IAstroObject tickableObject)
        {
            this.SpeedModiffer = 1f;
            this.timeAdded = timeAdded;
            this.tickableObject = tickableObject;
            this.date = StartingTime; //first we set the backing field
            this.Date = DateTime.Now; //then we set it again so we can change our object's position
        }