コード例 #1
0
        public override void OnLoad(ConfigNode node)
        {
            if (node == null)
            {
                return;
            }

            Util.DebugLog("");

            //version = Util.ConfigValue(node, "version", Version);     // get saved version, defaults to current version if none

            Settings ??= new Settings();                          // get trajectories settings from the config.xml file if it exists or create a new one
            if (Settings != null)
            {
                Settings.Load();

                DescentProfile.Start();
                Trajectory.Start();
                MapOverlay.Start();
                FlightOverlay.Start();
                NavBallOverlay.Start();
                MainGUI.Start();
                AppLauncherButton.Start();
            }
            else
            {
                Util.LogError("There was a problem with the config.xml settings file");
            }
        }
コード例 #2
0
        public override void OnLoad(ConfigNode node)
        {
            if (node == null)
            {
                return;
            }
            Util.DebugLog("");

            LoadedVesselsTrajectories ??= new List <Trajectory>();
            Settings ??= new Settings(); // get trajectories settings from the config.xml file if it exists or create a new one
            if (Settings != null)
            {
                Settings.Load();

                AttachVessel(FlightGlobals.ActiveVessel);
                MainGUI.Start();
                AppLauncherButton.Start();
            }
            else
            {
                Util.LogError("There was a problem with the config.xml settings file");
            }
        }