Esempio n. 1
0
 private void addWheel(Firespitter.cockpit.AnalogCounter counter, string wheelName)
 {
     if (wheelName != string.Empty)
     {
         Transform newWheel = base.internalProp.FindModelTransform(wheelName);
         if (newWheel != null)
         {
             counter.wheels.Add(newWheel);
         }
     }
 }
Esempio n. 2
0
    public void Start()
    {
        if (HighLogic.LoadedSceneIsFlight)
        {
            try
            {                
                button = internalProp.FindModelTransform(buttonName).gameObject;                
                buttonHandler = button.AddComponent<FSgenericButtonHandler>();                
                buttonHandler.mouseDownFunction = nextEngine;
                engineSelectionDialTransform = internalModel.FindModelTransform(engineSelectionDialName);                
                engineSelectionDial = new Firespitter.cockpit.AnalogCounter(engineSelectionDialTransform, selectionDefaultRotation, selectionRotationAxis);
            }
            catch
            {
                //useEngineSelection = false;
                Debug.Log("FStachometer: No button or dial, disabling engine selection");
            }

            RPMneedle = internalProp.FindModelTransform(RPMneedleName);
            heatNeedle = internalProp.FindModelTransform(heatNeedleName);
            thrustLimitNeedle = internalProp.FindModelTransform(thrustLimitNeedleName);
        }
    }
Esempio n. 3
0
    public void Start()
    {
        if (HighLogic.LoadedSceneIsFlight)
        {
            try
            {
                button        = internalProp.FindModelTransform(buttonName).gameObject;
                buttonHandler = button.AddComponent <FSgenericButtonHandler>();
                buttonHandler.mouseDownFunction = nextEngine;
                engineSelectionDialTransform    = internalModel.FindModelTransform(engineSelectionDialName);
                engineSelectionDial             = new Firespitter.cockpit.AnalogCounter(engineSelectionDialTransform, selectionDefaultRotation, selectionRotationAxis);
            }
            catch
            {
                //useEngineSelection = false;
                Debug.Log("FStachometer: No button or dial, disabling engine selection");
            }

            RPMneedle         = internalProp.FindModelTransform(RPMneedleName);
            heatNeedle        = internalProp.FindModelTransform(heatNeedleName);
            thrustLimitNeedle = internalProp.FindModelTransform(thrustLimitNeedleName);
        }
    }