-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathkarman.ks
More file actions
40 lines (36 loc) · 782 Bytes
/
karman.ks
File metadata and controls
40 lines (36 loc) · 782 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
print "Karman line sounding rocket.".
print "ignition".
lock throttle to 1.
stage.
wait 0.25.
wait until stage:ready.
print "removing launch clamps".
stage.
lock steering to up.
print "waiting for solid booster flameouts".
wait until count_flameout() > 0.
print "flamed out boosters. Staging.".
stage.
wait until altitude > 140_000.
print "now out of atmo. Staging decouplers.".
stage.
wait 1.
stage.
wait 1.
unlock steering.
unlock throttle.
print "now waiting to stage chutes.".
wait until altitude < 1700 and ship:velocity:surface:mag < 290.
print "staging chutes.".
stage.
wait 0.5.
stage.
function count_flameout {
local eng is list().
local count is 0.
list engines in engs.
for eng in engs {
if eng:flameout { set count to count +1. }
}
return count.
}