Beispiel #1
0
        void Start()
        {
            Log("Starting");
            try
            {
                mucore.init();
                vesselState = new VesselState();
                attitude    = new AttitudeController(this);
                stage       = new StageController(this);
                attitude.OnStart();
                stagestats            = new StageStats(stage);
                stagestats.editorBody = getVessel.mainBody;
                stagestats.OnModuleEnabled();
                stagestats.OnFixedUpdate();
                stagestats.RequestUpdate(this);
                stagestats.OnFixedUpdate();
                CreateButtonIcon();
                LaunchName = new string(getVessel.vesselName.ToCharArray());
                LaunchBody = getVessel.mainBody;
                launchdb   = new LaunchDB(this);
                launchdb.Load();

                mainWindow      = new Window.MainWindow(this, 6378070);
                flightMapWindow = new Window.FlightMapWindow(this, 548302);
                statsWindow     = new Window.StatsWindow(this, 6378070 + 4);

                GameEvents.onShowUI.Add(ShowGUI);
                GameEvents.onHideUI.Add(HideGUI);
            }
            catch (Exception ex)
            {
                Log(ex.ToString());
            }
        }
 void Start()
 {
     mucore.init();
     vesselState = new VesselState();
     attitude = new AttitudeController(this);
     stage = new StageController(this);
     attitude.OnStart();
     RenderingManager.AddToPostDrawQueue(3, new Callback(drawGUI));//start the GUI
     helpWindowPos = new Rect(windowPos.x+windowPos.width, windowPos.y, 0, 0);
     stagestats = new StageStats();
     stagestats.editorBody = vessel.mainBody;
     stagestats.OnModuleEnabled();
     stagestats.OnFixedUpdate();
     stagestats.RequestUpdate(this);
     stagestats.OnFixedUpdate();
     CreateButtonIcon();
 }
Beispiel #3
0
        void Start()
        {
            instance = this;
            Log("Starting");
            try
            {
                mucore.init();
                vesselState = new VesselState();
                attitude    = new AttitudeController(this);
                stage       = new StageController(this);
                attitude.OnStart();
                stagestats            = new StageStats(stage);
                stagestats.editorBody = getVessel.mainBody;
                stagestats.OnModuleEnabled();
                stagestats.OnFixedUpdate();
                stagestats.RequestUpdate(this);
                stagestats.OnFixedUpdate();
                CreateButtonIcon();
                LaunchName = new string(getVessel.vesselName.ToCharArray());
                LaunchBody = getVessel.mainBody;
                launchdb   = new LaunchDB(this);
                launchdb.Load();

                mainWindow      = new Window.MainWindow(this, 6378070);
                flightMapWindow = new Window.FlightMapWindow(this, 548302);
                statsWindow     = new Window.StatsWindow(this, 6378070 + 4);
                double h = 80f;
                if (FlightGlobals.ActiveVessel.mainBody.atmosphere)
                {
                    h = Math.Max(h, FlightGlobals.ActiveVessel.mainBody.atmosphereDepth + 10000f);
                    DestinationHeight = new EditableValue(h, locked: true) / 1000;
                }

                delayUT = double.NaN;

                GameEvents.onShowUI.Add(ShowGUI);
                GameEvents.onHideUI.Add(HideGUI);

                LoadKeybind();
            }
            catch (Exception ex)
            {
                Log(ex.ToString());
            }
        }
Beispiel #4
0
 void Start()
 {
     Log("Starting");
     try
     {
         mucore.init();
         vesselState = new VesselState();
         attitude = new AttitudeController(this);
         stage = new StageController(this);
         attitude.OnStart();
         stagestats = new StageStats();
         stagestats.editorBody = getVessel.mainBody;
         stagestats.OnModuleEnabled();
         stagestats.OnFixedUpdate();
         stagestats.RequestUpdate(this);
         stagestats.OnFixedUpdate();
         CreateButtonIcon();
         LaunchName = new string(getVessel.vesselName.ToCharArray());
         LaunchBody = getVessel.mainBody;
         launchdb = new LaunchDB(this);
         launchdb.Load();
         mainWindow = new Window.MainWindow(this, 6378070);
         flightMapWindow = new Window.FlightMapWindow(this, 548302);
     }
     catch (Exception ex)
     {
         Log(ex.ToString());
     }
 }