Simplify lots of code in the launch sequence.
This commit is contained in:
parent
401f51425f
commit
642e5b17c5
4 changed files with 33 additions and 47 deletions
|
@ -6,6 +6,18 @@ function GetPitch {
|
|||
return 90 - vectorangle(SHIP:UP:FOREVECTOR, v).
|
||||
}
|
||||
|
||||
function GetAscentVector {
|
||||
parameter minPitch.
|
||||
// face prograde, but hold a solid eastern heading and don't
|
||||
// rotate the ship
|
||||
local newHeading is lookdirup(SHIP:SRFPROGRADE:FOREVECTOR,
|
||||
heading(90, 0, 270):TOPVECTOR).
|
||||
if GetPitch(newHeading:FOREVECTOR) < minPitch {
|
||||
set newHeading to heading(90, minPitch, 270).
|
||||
}
|
||||
return newHeading.
|
||||
}
|
||||
|
||||
function AddCircularizationNode {
|
||||
parameter usePeriapsis is false.
|
||||
local target is SHIP:ORBIT:APOAPSIS.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue