updateEngineThrust() 공개 정적인 메소드

public static updateEngineThrust ( ModuleEngines engine, float minThrust, float maxThrust ) : void
engine ModuleEngines
minThrust float
maxThrust float
리턴 void
예제 #1
0
        private void updateEngineThrust()
        {
            ModuleEngines engine = part.GetComponent <ModuleEngines>();

            if (engine != null)
            {
                float scale           = getEngineScale();
                float thrustScalar    = Mathf.Pow(scale, thrustScalePower);
                float thrustPerEngine = engineThrust * thrustScalar;
                float totalThrust     = thrustPerEngine * engineModels.model.numberOfEngines;
                guiEngineThrust = totalThrust;
                SSTUStockInterop.updateEngineThrust(engine, engine.minThrust, totalThrust);
            }
            else
            {
                print("Cannot update engine thrust -- no engine module found!");
                guiEngineThrust = 0;
            }
        }