Beispiel #1
0
        void Awake()
        {
            this.Log("Awake");
            globalSettings   = TacLifeSupport.Instance.globalSettings;
            gameSettings     = TacLifeSupport.Instance.gameSettings;
            rosterWindow     = new RosterWindow(globalSettings, gameSettings);
            monitoringWindow = new LifeSupportMonitoringWindow(this, globalSettings, gameSettings, rosterWindow);
            GameEvents.onGUIApplicationLauncherReady.Add(OnGUIAppLauncherReady);
            OnGUIAppLauncherReady();
            configFilename = IOUtils.GetFilePathFor(this.GetType(), "LifeSupport.cfg");

            //Check if DeepFreeze is installed and set bool.
            var DeepFreezeassembly = (from a in AppDomain.CurrentDomain.GetAssemblies()
                                      where a.FullName.StartsWith("DeepFreeze")
                                      select a).FirstOrDefault();

            if (DeepFreezeassembly != null)
            {
                IsDFInstalled = true;
            }
            else
            {
                IsDFInstalled = false;
            }
        }
Beispiel #2
0
 public LifeSupportMonitoringWindow(LifeSupportController controller, GlobalSettings globalSettings, TacGameSettings gameSettings, RosterWindow rosterWindow)
     : base("Life Support Monitoring", 300, 300)
 {
     this.gameSettings = gameSettings;
     this.rosterWindow = rosterWindow;
     version           = Utilities.GetDllVersion(this);
     windowPos.y       = 75;
 }
 public LifeSupportMonitoringWindow(LifeSupportController controller, Settings settings, SettingsWindow settingsWindow, RosterWindow rosterWindow)
     : base("Life Support Monitoring", 300, 300)
 {
     this.controller     = controller;
     this.settings       = settings;
     this.settingsWindow = settingsWindow;
     this.rosterWindow   = rosterWindow;
 }
Beispiel #4
0
 public LifeSupportMonitoringWindow(AppLauncherToolBar TACMenuAppLToolBar, RosterWindow rosterWindow)
     : base(TACMenuAppLToolBar, Localizer.Format("#autoLOC_TACLS_00001"), 300, 300)
 {
     this.rosterWindow   = rosterWindow;
     version             = Utilities.GetDllVersion(this);
     DeepFreezeInstalled = RSTUtils.Utilities.IsModInstalled("DeepFreeze");
     cacheLocalStrings();
     windowPos.y = 75;
     SetVisible(true);
 }
        public LifeSupportMonitoringWindow(AppLauncherToolBar TACMenuAppLToolBar, RosterWindow rosterWindow)
            : base(TACMenuAppLToolBar, "Life Support Monitoring", 300, 300)
        {
            //this.gameSettings = gameSettings;
            this.rosterWindow   = rosterWindow;
            version             = Utilities.GetDllVersion(this);
            DeepFreezeInstalled = RSTUtils.Utilities.IsModInstalled("DeepFreeze");

            windowPos.y = 75;
            SetVisible(true);
        }
        void Awake()
        {
            this.Log("Awake");
            globalSettings   = TacLifeSupport.Instance.globalSettings;
            gameSettings     = TacLifeSupport.Instance.gameSettings;
            rosterWindow     = new RosterWindow(globalSettings, gameSettings);
            monitoringWindow = new LifeSupportMonitoringWindow(this, globalSettings, gameSettings, rosterWindow);

            button = new ButtonWrapper(new Rect(Screen.width * 0.75f, 0, 32, 32), "ThunderAerospace/TacLifeSupport/Textures/greenIcon",
                                       "LS", "TAC Life Support Monitoring Window", OnIconClicked, "FlightIcon");

            configFilename = IOUtils.GetFilePathFor(this.GetType(), "LifeSupport.cfg");
        }
        void Awake()
        {
            Debug.Log("TAC Life Support (LifeSupportController) [" + this.GetInstanceID().ToString("X") + "][" + Time.time + "]: Awake");
            Instance = this;

            knownCrew    = new Dictionary <string, CrewMemberInfo>();
            knownVessels = new Dictionary <Guid, VesselInfo>();

            settings         = new Settings();
            settingsWindow   = new SettingsWindow(settings);
            rosterWindow     = new RosterWindow();
            monitoringWindow = new LifeSupportMonitoringWindow(this, settings, settingsWindow, rosterWindow);

            icon = new Icon <LifeSupportController>(new Rect(Screen.width * 0.75f, 0, 32, 32), "icon.png", "LS",
                                                    "Click to show the Life Support Monitoring Window", OnIconClicked);

            configFilename = IOUtils.GetFilePathFor(this.GetType(), "LifeSupport.cfg");
        }