Beispiel #1
0
        public void UpdateDirections(AvidWindow launchWindow, AvidDirection referenceDirection)
        {
            if (AvidWindow.IsNullOrZero(launchWindow) ||
                (launchWindow.Ring == AvidRing.Magenta && referenceDirection == AvidDirection.Undefined))
            {
                ResetEvasionInfo();
                return;
            }

            var impactWindow = _avidCalculator.GetOppositeWindow(launchWindow);
            var axis         = _avidCalculator.GetOrientationWithoutRoll(impactWindow, referenceDirection);

            ImpactWindow = axis.Nose;
            EvasionUp    = axis.Top;
            EvasionDown  = axis.Bottom;
            EvasionLeft  = axis.Port;
            EvasionRight = axis.Starboard;
            OnEvasionChanged();
        }
 public EvasionInfoModel(AvidWindow impactWindow, AvidDirection referenceDirection)
 {
     _avidCalculator = ServiceFactory.Library.AvidCalculator;
     UpdateDirections(_avidCalculator.GetOppositeWindow(impactWindow), referenceDirection);
 }
Beispiel #3
0
 public EvasionInfoModel(AvidWindow impactWindow, AvidDirection referenceDirection)
 {
     _avidCalculator = ServiceFactory.Library.AvidCalculator;
     UpdateDirections(_avidCalculator.GetOppositeWindow(impactWindow), referenceDirection);
 }