Beispiel #1
0
 public PixelPath(Vector3d[] path, KSPConsoleModule.RgbaColor color, bool dashed)
 {
     Color   = color;
     Path    = path;
     Dashed  = dashed;
     Visible = true;
 }
            public PixelPath AddPixelPath(Vector3d[] path, KSPConsoleModule.RgbaColor color, bool dashed)
            {
                PixelPath pixelPath = new PixelPath(path, color, dashed);

                KSPContext.CurrentContext.AddMarker(pixelPath);

                return(pixelPath);
            }
 public GroundMarker(KSPOrbitModule.GeoCoordinates geoCoordinates, KSPConsoleModule.RgbaColor color,
                     double rotation)
 {
     Color          = color;
     GeoCoordinates = geoCoordinates;
     Rotation       = rotation;
     Visible        = true;
 }
            public GroundMarker AddGroundMarker(KSPOrbitModule.GeoCoordinates geoCoordinates,
                                                KSPConsoleModule.RgbaColor color, double rotation)
            {
                GroundMarker groundMarker = new GroundMarker(geoCoordinates, color, rotation);

                KSPContext.CurrentContext.AddMarker(groundMarker);

                return(groundMarker);
            }
            private const int FlightLayer = 15; // Supposedly the layer for UI effects in flight camera.

            public VectorRenderer(Func <Vector3d> startProvider, Func <Vector3d> endProvider,
                                  KSPConsoleModule.RgbaColor color, string label, double width, bool pointy)
            {
                this.startProvider = startProvider;
                this.endProvider   = endProvider;
                Color    = color;
                Scale    = 1.0;
                Width    = width;
                Pointy   = pointy;
                labelStr = label;
            }
            public VectorRenderer AddLine(Func <Vector3d> startProvider, Func <Vector3d> endProvider,
                                          KSPConsoleModule.RgbaColor color,
                                          string label, double width)
            {
                VectorRenderer renderer =
                    new VectorRenderer(startProvider, endProvider, color, label, width, false);

                renderer.Visible = true;
                KSPContext.CurrentContext.AddMarker(renderer);

                return(renderer);
            }
            public VectorRenderer AddVector(Func <Vector3d> startProvider, Func <Vector3d> endProvider,
                                            KSPConsoleModule.RgbaColor color, string label, double width)
            {
                Vessel vessel = FlightGlobals.ActiveVessel;

                VectorRenderer renderer =
                    new VectorRenderer(startProvider, endProvider, color, label, width, true);

                renderer.Visible = true;
                KSPContext.CurrentContext.AddMarker(renderer);

                return(renderer);
            }