Ejemplo n.º 1
0
        public PwrPartList(string prtName, string prtTitle, string prtModuleName, bool prtSubsystem, string prtPower, float prtPowerF, bool prtActive,
                           bool prtSolarDependant, Part prtRef)
        {
            PrtName                      = prtName;
            PrtTitle                     = prtTitle;
            PrtReference                 = prtRef;
            HighlightOn                  = false;
            PrtModuleName                = prtModuleName;
            PrtSubsystem                 = prtSubsystem;
            PrtPower                     = prtPower;
            PrtPowerF                    = prtPowerF;
            PrtActive                    = prtActive;
            PrtSolarDependant            = prtSolarDependant;
            PrtEditorInclude             = true;
            PrtUserEditorInclude         = true;
            ValidprtEmergShutDn          = AmpYear.Instance.AYsettings.ValidPartModuleEmergShutDn.Any(x => x.Name == prtModuleName);
            PrtEmergShutDnInclude        = ValidprtEmergShutDn;
            PrtPreEmergShutDnStateActive = prtActive;
            KeyValuePair <ValidEmergencyPartModule, ESPValues> tmpEspPair = AmpYear.Instance.AYsettings.PartModuleEmergShutDnDflt
                                                                            .FirstOrDefault(
                a => a.Key.Name == prtModuleName);

            PrtEmergShutDnPriority = tmpEspPair.Key != null ? tmpEspPair.Value.EmergShutPriority : ESPPriority.MEDIUM;
        }
Ejemplo n.º 2
0
 public ESPValues(bool emergShutDnDflt, ESPPriority emergShutPriority)
 {
     EmergShutDnDflt   = emergShutDnDflt;
     EmergShutPriority = emergShutPriority;
 }