Exemplo n.º 1
0
 //конструктор для создания цели с конкретными параметрами
 public Target(Course peleng_, float distance_, Course course_, float speed_)
 {
     distance = distance_;
     speed = speed_;
     course = course_;
     peleng = peleng_;
 }
Exemplo n.º 2
0
        public float speed; //скорость цели

        #endregion Fields

        #region Constructors

        //конструктор для создания цели с нулевыми параметрами
        public Target()
        {
            distance = 0;
            speed = 0;
            Course course_ = new Course(0, 0);
            course = course_;
            Course peleng_ = new Course(0, 0);
            peleng = peleng_;
        }
 public void SetTargetInformation(Course peleng, float distance, Course targetCourse, float targetSpeed)
 {
     targ.peleng = peleng;
     targ.distance = distance;
     targ.course = targetCourse;
     targ.speed = targetSpeed;
 }
Exemplo n.º 4
0
 //старт алгоритма торпеды
 public void Algorithm(Course targPeleng_, float targDistance_, Course targCourse_, float targSpeed_)
 {
     alg.SetTargetInformation(targPeleng_, targDistance_, targCourse_, targSpeed_);
        alg.Process();
 }