SetThrottle() public method

public SetThrottle ( double throttle, int engineIds = null ) : void
throttle double
engineIds int
return void
Exemplo n.º 1
0
        public override void Update(double elapsedTime, SpaceCraftBase spaceCraft)
        {
            double timeRatio = (elapsedTime - StartTime) / Duration;

            spaceCraft.SetThrottle(_throttle * timeRatio);
        }
Exemplo n.º 2
0
        // Interpolate between current and target throttle over the duration
        public override void Update(double elapsedTime, SpaceCraftBase spaceCraft)
        {
            double ratio = (elapsedTime - StartTime) / Duration;

            spaceCraft.SetThrottle(_currentThrottle * (1 - ratio) + _targetThrottle * ratio);
        }
Exemplo n.º 3
0
 public override void Finalize(SpaceCraftBase spaceCraft)
 {
     spaceCraft.SetThrottle(_throttle);
 }
Exemplo n.º 4
0
        public override void Update(double elapsedTime, SpaceCraftBase spaceCraft)
        {
            double shutdownRatio = (elapsedTime - StartTime) / Duration * 2;

            spaceCraft.SetThrottle(_currentThrottle * (1 - shutdownRatio), _engineIds);
        }