//constructor public Mission(int _howmanydays, List<Astronaut> _l_astronaut, int _hq_x = 700, int _hq_y = 1000) { howmanydays = _howmanydays; beginMission = false; l_astronaut = _l_astronaut; click_hq = new int[] { _hq_x, _hq_y }; map_hq = new Place(0.0, 0.0, "HQ", click_hq); l_day = new List<Day>(); for (int i = 0; i <= howmanydays; i++) { Future Day = new Future(i, map_hq); } //generate l_activity from XML l_place = new List<Place>(); }
public void changeDayStatus(Day d, string to) { Day newDay = d; // in case d is already converted in to switch (to) { case "past": if (!(d is Past)) { newDay = new Past(d.Number, d.Map_hq); } break; case "present": if (!(d is Present)) { newDay = new Present(d.Number, d.Map_hq); } break; default: //case "future": if (!(d is Future)) { newDay = new Future(d.Number, d.Map_hq); } break; } l_day[d.Number] = newDay; //newDay.L_activity = d.L_activity; WRITE A SET ! newDay.Report = d.Report; newDay.Outside = d.Outside; }