Beispiel #1
0
            public override void DoLayout(GaugeSet set)
            {
                Reset();

                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_SETS);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_INDICATOR);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_CAM);

                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_ORBIT);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_INCL);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_TIMETOPEA);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_TIMETOAPA);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_PEA);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_APA);


                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_FUEL);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_OXID);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_EVAMP);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_MONO);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_AMP);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_CHARGE);


                // horizontal gauges
                int hDY = (int)(configuration.horizontalGaugeHeight * gaugeScaling) + Gauges.LAYOUT_GAP;

                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_BIOME, 10, 60 + 0 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_LATITUDE, 10, 60 + 1 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_LONGITUDE, 10, 60 + 2 * hDY);
            }
Beispiel #2
0
 private bool Declutter(GaugeSet set, int id)
 {
     foreach (int other in set)
     {
         if (!set.IsGaugeEnabled(other))
         {
             continue;
         }
         if (id != other)
         {
             Pair <int, int> position = set.GetWindowPosition(id);
             Pair <int, int> cmp      = set.GetWindowPosition(other);
             if (Math.Abs(position.first - cmp.first) < MIN_GAUGE_DISTANCE && Math.Abs(position.second - cmp.second) < MIN_GAUGE_DISTANCE)
             {
                 int x = position.first + MIN_GAUGE_DISTANCE;
                 int y = position.second + MIN_GAUGE_DISTANCE;
                 if (x >= Screen.width - NanoGauges.configuration.verticalGaugeWidth)
                 {
                     x = 0;
                 }
                 if (y >= Screen.height - NanoGauges.configuration.verticalGaugeHeight)
                 {
                     y = 0;
                 }
                 Pair <int, int> newPosition = new Pair <int, int>(x, y);
                 set.SetWindowPosition(id, newPosition);
                 return(true);
             }
         }
     }
     return(false);
 }
Beispiel #3
0
            public void Layout(GaugeSet set)
            {
                Log.Info("layout " + GetType() + ", set " + set);
                //
                // move all gauges to 0/0 to find gauges that are unaffected by layout
                foreach (AbstractGauge g in gauges)
                {
                    int id = g.GetWindowId();
                    set.SetWindowPosition(id, Constants.ORIGIN);
                }
                //
                DoLayout(set);
                //
                EnableGauges(set);

                Reset();
                foreach (AbstractGauge g in gauges)
                {
                    int id = g.GetWindowId();
                    if (set.GetWindowPosition(id).Equals(Constants.ORIGIN))
                    {
                        AddToSpare(set, id);
                    }
                }

                Log.Detail("layout done for " + set);
            }
Beispiel #4
0
            public override void DoLayout(GaugeSet set)
            {
                Reset();

                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_SETS);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_INDICATOR);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_CAM);

                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_G);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_ACCL);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VACCL);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_HACCL);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_MASS);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_ATM);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_TWR);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_THRUST);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_ISPE);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_DISP);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_TIMETOAPA);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_APA);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VAI);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VVI);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_MACH);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_SPD);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VSI);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_ALTIMETER);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VT);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_RADAR_ALTIMETER);


                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_FUEL);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_OXID);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_FLOW);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_SRB);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_AIRIN);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_AIRPCT);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_PROPELLANT);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_Q);


                // horizontal gauges
                int hDY = (int)(configuration.horizontalGaugeHeight * gaugeScaling) + Gauges.LAYOUT_GAP;

                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_BIOME, 10, 60 + 0 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_LATITUDE, 10, 60 + 1 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_LONGITUDE, 10, 60 + 2 * hDY);
            }
Beispiel #5
0
            // common layout for horizontal gauges
            protected void LayoutHorizontalGauges(GaugeSet set)
            {
                // horizontal gauges
                int hDY = (int)(configuration.horizontalGaugeHeight * gaugeScaling) + Gauges.LAYOUT_GAP;

                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_VESSEL, MARGIN_X_TOP_LEFT_BLOCK, MARGIN_Y_TOP_LEFT_BLOCK + 0 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_BIOME, MARGIN_X_TOP_LEFT_BLOCK, MARGIN_Y_TOP_LEFT_BLOCK + 1 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_LATITUDE, MARGIN_X_TOP_LEFT_BLOCK, MARGIN_Y_TOP_LEFT_BLOCK + 2 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_LONGITUDE, MARGIN_X_TOP_LEFT_BLOCK, MARGIN_Y_TOP_LEFT_BLOCK + 3 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_CAMERA, MARGIN_X_TOP_LEFT_BLOCK, MARGIN_Y_TOP_LEFT_BLOCK + 4 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_NAV, MARGIN_X_TOP_LEFT_BLOCK, MARGIN_Y_TOP_LEFT_BLOCK + 5 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_APOAPSIS, MARGIN_X_TOP_LEFT_BLOCK, MARGIN_Y_TOP_LEFT_BLOCK + 6 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_PERIAPSIS, MARGIN_X_TOP_LEFT_BLOCK, MARGIN_Y_TOP_LEFT_BLOCK + 7 * hDY);
            }
Beispiel #6
0
            private void ReadWindowPositions(BinaryReader reader, GaugeSet set)
            {
                Log.Info("loading window positions");
                int count = reader.ReadInt16();

                Log.Detail("loading " + count + " window positions");
                for (int i = 0; i < count; i++)
                {
                    int id = reader.ReadInt32();
                    int x  = reader.ReadInt16();
                    int y  = reader.ReadInt16();
                    Log.Trace("read window position for window id " + id + ": " + x + "/" + y);
                    set.SetWindowPosition(id, x, y);
                }
            }
Beispiel #7
0
 protected void AddToSpare(GaugeSet set, int windowId)
 {
     if (gauges.ContainsId(windowId))
     {
         int MARGIN_X_SPARE = Screen.width / 2;
         int MARGIN_Y_SPARE = 100;
         int x = MARGIN_X_SPARE + spareIndex * (verticalGaugeWidth);
         int y = MARGIN_Y_SPARE + spareRow * (verticalGaugeHeight + Gauges.LAYOUT_GAP);
         // next line ?
         if (x + verticalGaugeWidth > Screen.width)
         {
             spareIndex = 0;
             x          = MARGIN_X_SPARE;
             spareRow++;
             y = MARGIN_Y_SPARE + spareRow * (verticalGaugeHeight + Gauges.LAYOUT_GAP);
         }
         set.SetWindowPosition(windowId, x, y);
         spareIndex++;
     }
 }
Beispiel #8
0
 public void ResetWindowPositions(Gauges gauges)
 {
     currentGaugeSet.SetWindowPosition(Constants.WINDOW_ID_ABOUT, 50, 50);
     currentGaugeSet.SetWindowPosition(Constants.WINDOW_ID_CONFIG, 50, 50);
     LayoutGaugeSet(currentGaugeSet, new DefaultLayout(gauges, this));
 }
            public override void DoLayout(GaugeSet set)
            {
                Reset();

                int LAYOUT_CELL_X  = verticalGaugeWidth + Gauges.LAYOUT_GAP;
                int LAYOUT_CELL_Y  = verticalGaugeHeight + Gauges.LAYOUT_GAP;
                int LAYOUT_RANGE_X = 3 * LAYOUT_CELL_X / 2;
                int LAYOUT_RANGE_Y = 3 * LAYOUT_CELL_Y / 2;


                int x0  = Screen.width - LAYOUT_CELL_X;
                int y0  = Screen.height - (int)(670 * gaugeScaling);
                int vDX = LAYOUT_CELL_X;
                int vDY = LAYOUT_CELL_Y;


                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_SETS);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_INDICATOR);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_CAM);

                int n = 0;

                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_Q, x0 - 11 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_TEMP, x0 - 10 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_GRAVIMETER, x0 - 9 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_BAROMETER, x0 - 8 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_SEISMOMETER, x0 - 7 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_SHIELD, x0 - 6 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_IAS, x0 - 5 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_GLIDE, x0 - 4 * vDX, y0 + n * vDY);
                n = 1;
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_KARBONITE, x0 - 11 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_O2, x0 - 10 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_CO2, x0 - 9 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_CARBONDIOXIDE, x0 - 8 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_H2O, x0 - 7 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_WH2O, x0 - 6 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_WASTE, x0 - 5 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_FOOD, x0 - 4 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_ORE, x0 - 3 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_KETHANE, x0 - 2 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_KAIRIN, x0 - 1 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_CRAP, x0 - 0 * vDX, y0 + n * vDY);
                //
                //
                n = 2;
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_ORBIT, x0 - 11 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_INCL, x0 - 10 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_TIMETOAPA, x0 - 9 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_TIMETOPEA, x0 - 8 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_PEA, x0 - 7 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_APA, x0 - 6 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_IMPACT, x0 - 5 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_ABLAT, x0 - 4 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_HEAT, x0 - 3 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_EXTTEMP, x0 - 2 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_ATMTEMP, x0 - 1 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_DRILLTEMP, x0 - 0 * vDX, y0 + n * vDY);

                n = 3;
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_THRUST, x0 - 11 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_TWR, x0 - 10 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_ISPE, x0 - 9 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_DISP, x0 - 8 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_MASS, x0 - 7 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_AOA, x0 - 6 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_VVI, x0 - 5 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_VAI, x0 - 4 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_DTGT, x0 - 3 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_VTGT, x0 - 2 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_G, x0 - 1 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_MAXG, x0 - 0 * vDX, y0 + n * vDY);


                n = 4;
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_FUEL, x0 - 11 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_OXID, x0 - 10 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_FLOW, x0 - 9 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_SRB, x0 - 8 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_MONO, x0 - 7 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_CHARGE, x0 - 6 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_AMP, x0 - 5 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_XENON, x0 - 4 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_AIRIN, x0 - 3 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_AIRPCT, x0 - 2 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_PROPELLANT, x0 - 1 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_EVAMP, x0 - 0 * vDX, y0 + n * vDY);

                n = 5;
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_SPD, x0 - 11 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_VSI, x0 - 10 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_HSPD, x0 - 9 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_OSPD, x0 - 8 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_MACH, x0 - 7 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_ACCL, x0 - 6 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_HACCL, x0 - 5 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_VACCL, x0 - 4 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_VT, x0 - 3 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_ALTIMETER, x0 - 2 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_RADAR_ALTIMETER, x0 - 1 * vDX, y0 + n * vDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_ATM, x0 - 0 * vDX, y0 + n * vDY);

                // horizontal gauges
                LayoutHorizontalGauges(set);
            }
Beispiel #10
0
 protected void SetGaugePosition(GaugeSet set, int windowId, Pair <int, int> position)
 {
     set.SetWindowPosition(windowId, position);
 }
Beispiel #11
0
            public override void DoLayout(GaugeSet set)
            {
                Reset();

                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_SETS);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_INDICATOR);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_CAM);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_ORBIT);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_INCL);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_PEA);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_APA);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_TIMETOPEA);
                AddToTopBlock(set, Constants.WINDOW_ID_GAUGE_TIMETOAPA);

                AddToLeftBlock(set, Constants.WINDOW_ID_GAUGE_DTGT);
                AddToLeftBlock(set, Constants.WINDOW_ID_GAUGE_VTGT);
                AddToLeftBlock(set, Constants.WINDOW_ID_GAUGE_IMPACT);
                AddToLeftBlock(set, Constants.WINDOW_ID_GAUGE_TEMP);
                AddToLeftBlock(set, Constants.WINDOW_ID_GAUGE_GRAV);
                AddToLeftBlock(set, Constants.WINDOW_ID_GAUGE_HEAT);
                AddToLeftBlock(set, Constants.WINDOW_ID_GAUGE_EXTTEMP);
                AddToLeftBlock(set, Constants.WINDOW_ID_GAUGE_ATMTEMP);
                AddToLeftBlock(set, Constants.WINDOW_ID_GAUGE_DRILLTEMP);

                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_G);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_MAXG);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VACCL);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_HACCL);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_ACCL);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_ATM);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_ISPE);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_DISP);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_THRUST);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_TWR);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_MASS);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_AOA);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VAI);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VVI);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_OSPD);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_HSPD);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_MACH);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_SPD);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VSI);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_ALTIMETER);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_VT);
                AddToLeftNavballBlock(set, Constants.WINDOW_ID_GAUGE_RADAR_ALTIMETER);


                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_FUEL);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_OXID);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_FLOW);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_MONO);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_SRB);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_XENON);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_CHARGE);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_AMP);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_AIRIN);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_AIRPCT);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_PROPELLANT);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_EVAMP);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_ABLAT);
                AddToRightNavballBlock(set, Constants.WINDOW_ID_GAUGE_Q);


                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_ORE);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_O2);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_CO2);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_FOOD);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_H2O);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_WH2O);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_KARBONITE);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_WASTE);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_KETHANE);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_KAIRIN);
                AddToRightBlock(set, Constants.WINDOW_ID_GAUGE_SHIELD);

                // horizontal gauges
                int hDY = (int)(horizontalGaugeHeight * gaugeScaling) + Gauges.LAYOUT_GAP;

                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_BIOME, 10, 60 + 0 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_LATITUDE, 10, 60 + 1 * hDY);
                set.SetWindowPosition(Constants.WINDOW_ID_GAUGE_LONGITUDE, 10, 60 + 2 * hDY);
            }
Beispiel #12
0
 public void SetWindowPosition(AbstractGauge gauge)
 {
     currentGaugeSet.SetWindowPosition(gauge.GetWindowId(), gauge.GetX(), gauge.GetY());
 }