/// <summary>
        /// Use for constructor-like stuff.
        /// </summary>
        void Start()
        {
            setupTexture();
            viewer = new VesselViewer();
            settings = viewer.basicSettings;

            GameEvents.OnGameSettingsApplied.Add(initToolbar);
            GameEvents.onGameStatePostLoad.Add(ReloadSettings);
        }
 public VViewSimpleMenuItem(string label, VesselView.ViewerSettings settings, string propertyToChange, string propertyToPrint/*, bool valueDirect, int value*/)
 {
     this.label = label;
     this.settings = settings;
     this.targetProperty = propertyToChange;
     this.displayProperty = propertyToPrint;
     //this.propertyToChangeID = propertyToChange;
     //this.propertyToPrintID = propertyToPrint;
     //this.changeValueDirect = valueDirect;       
     //this.changeValue = value;
     //this.changeMode = changeMode;
 }
 public VViewSimpleMenuItem(string label, VesselView.ViewerSettings settings, string propertyToChange, string propertyToPrint /*, bool valueDirect, int value*/)
 {
     this.label           = label;
     this.settings        = settings;
     this.targetProperty  = propertyToChange;
     this.displayProperty = propertyToPrint;
     //this.propertyToChangeID = propertyToChange;
     //this.propertyToPrintID = propertyToPrint;
     //this.changeValueDirect = valueDirect;
     //this.changeValue = value;
     //this.changeMode = changeMode;
 }
        /// <summary>
        /// Use for constructor-like stuff.
        /// </summary>
        public void Start()
        {
            Debug.Log("VesselView.VesselViewPlugin.Start 1");
            setupTexture();
            Debug.Log("VesselView.VesselViewPlugin.Start 2");
            viewer = new VesselViewer();
            Debug.Log("VesselView.VesselViewPlugin.Start 3");

            settings = viewer.basicSettings;
            if (settings == null)
                Debug.Log("VesselViewPlugin.Start, settings is null");

            GameEvents.OnGameSettingsApplied.Add(initToolbar);
            GameEvents.onGameStatePostLoad.Add(ReloadSettings);
            Debug.Log("VesselView.VesselViewPlugin.Start 5");

        }
 /// <summary>
 /// Use for constructor-like stuff.
 /// </summary>
 void Start()
 {
     setupTexture();
     viewer   = new VesselViewer();
     settings = viewer.basicSettings;
 }
 public void Start()
 {
     viewer = new VesselViewer();
     settings = viewer.basicSettings;
     setupConfig();
     setupMenus();
     ready = true;
 }
 /// <summary>
 /// Use for constructor-like stuff.
 /// </summary>
 void Start()
 {
     setupTexture();
     viewer = new VesselViewer();
     settings = viewer.basicSettings;
 }
Beispiel #8
0
 private Color getPartColorSelectMode(Part part, ViewerSettings settings)
 {
     Color darkGreen = Color.green;
     darkGreen.g = 0.6f;
     darkGreen.r = 0.3f;
     darkGreen.b = 0.3f;
     Part selectedPart = settings.selectedPart;
     if (selectedPart == null) return Color.red;
     if (part == selectedPart) return Color.green;
     if (settings.selectionSymmetry) {
         if (selectedPart.symmetryCounterparts.Contains(part)) return darkGreen;
     }
     if (partIsOnWayToRoot(part, selectedPart, settings.ship.rootPart)) return Color.yellow;
     if (part == settings.ship.rootPart) return Color.magenta;
     return Color.white;
 }