Example #1
0
 public CSimpleSector(EConstraints ForceConstraint, ESectorialBrigade MySectorialBrigade, DateTime StartOfYear)
 {
     this.ForceConstraint    = ForceConstraint;
     this.MySectorialBrigade = MySectorialBrigade;
     AssignmentStrategy.BrigadesData[MySectorialBrigade].RegisterSector(this);
     this.StartOfYear = StartOfYear.AddDays((AssignmentStrategy.BrigadesData[MySectorialBrigade].MySectors.Count - 1) * 7);
 }
Example #2
0
 public CSimpleBattalion(EConstraints Force, int Price)
 {
     this.Location     = new Point2D();
     this.Reservations = new List <Reservation>();
     this.Force        = Force;
     this.Price        = Price;
     this.Justice      = 0;
 }
Example #3
0
 public CSimpleBattalion(string Name, EConstraints Force)
 {
     this.Location     = new Point2D();
     this.Reservations = new List <Reservation>();
     this.Force        = Force;
     this.Justice      = Shared.Next(3);
     this.Name         = Name;
 }
Example #4
0
        private CSimpleBattalion CreateBattalion(int UID, string Name, EConstraints Constraints, bool IsReservedDuty = false)
        {
            CSimpleBattalion Battalion = new CSimpleBattalion(Name, Constraints);

            Battalion.SetUID(UID);
            Battalion.IsReservedDuty = IsReservedDuty;
            int Reseversions = Shared.Next(2);

            for (int j = 0; j < Reseversions; j++)
            {
                Reservation r = new Reservation();
                r.Date       = (new DateTime(2018, 1, 1)).AddDays(Shared.Next(365));
                r.Importance = (EImportance)(Shared.Next(5) + 1);
                Battalion.Reservations.Add(r);
            }

            return(Battalion);
        }