Пример #1
0
        public void AddLap(Lap lap)
        {
            // This method updates the list of laps. It is called when the lap is finished, and can add a lap to the list.

            // I think it should be looping through this.laps and updating that way, not sure tbh.
            this.laps.Add(lap);

            //this.stream.SubmitLap(lap, this.id);

            this.updatelaps(lap);
        }
Пример #2
0
        private void updatelaps(Lap lap)
        {
            // Updates the list of laps on the MainWindow.

            float  num  = lap.LapNumber;
            float  sec1 = lap.Sector1;
            float  sec2 = lap.Sector2;
            float  sec3 = lap.Sector3;
            string time = lap.ToString();

            string result = "Lap " + num + ": Time:" + time;


            this.parent.AddLapToPreviousLaps(result);
        }