Kerbal Engineer Redux#
Provides functionality to interact with the Kerbal Engineer Redux mod. Tested with Kerbal Engineer Redux 1.1.9.5.
Example#
The following example prints the delta-v and thrust-to-weight ratio of each stage of the active vessel, from the current stage onward, then the time to burn 500 m/s:
import krpc
conn = krpc.connect(name="Kerbal Engineer Redux Example")
vessel = conn.space_center.active_vessel
ker = conn.kerbal_engineer_redux
for stage in reversed(ker.stages(vessel)):
print(
"Stage %d: %.0f m/s, TWR %.2f"
% (stage.number, stage.delta_v, stage.available_twr)
)
burn = ker.burn_time(vessel, 500)
if burn is None:
print("Not enough delta-v for the burn")
else:
print("A 500 m/s burn takes %.1f seconds" % burn.duration)