public void LoadFromXml(XElement xTrackerTrigger) { if (xTrackerTrigger != null) { if (Enum.TryParse(xTrackerTrigger.GetElementValueTrimmed("TriggeringEvent"), out YawTrackerOrientationEvent trig)) { TriggeringEvent = trig; } else { TriggeringEvent = YawTrackerOrientationEvent.Yaw0; } FireLimitPerReset = (uint)xTrackerTrigger.GetElementValueInt("FireLimitPerZero"); RotCondition.LoadFromXml(xTrackerTrigger.Element("RotationCondition")); } }
public Trigger(YawTracker triggeringTracker) { TriggeringTracker = triggeringTracker; RotCondition = new RotationCondition(this); TriggeringEvent = YawTrackerOrientationEvent.Yaw0Yaw180; }