Pin down more of the logic for flight control.
This commit is contained in:
parent
5b9da6f0f1
commit
34ddc42b37
5 changed files with 78 additions and 17 deletions
|
@ -1,13 +1,36 @@
|
|||
function launchButtonPressed {
|
||||
run "launch".
|
||||
run "launch"(
|
||||
targetApo:TEXT:ToNumber(),
|
||||
gravTurnStart:TEXT:ToNumber(),
|
||||
initialPitch:TEXT:ToNumber()
|
||||
).
|
||||
}
|
||||
|
||||
// Button panel
|
||||
local interface is gui(200).
|
||||
set interface:X to 150.
|
||||
set interface:Y to 900.
|
||||
|
||||
// Launch button
|
||||
local launchButton is interface:addbutton("Launch").
|
||||
local hBox is interface:AddHBox().
|
||||
hBox:AddLabel("Initial Pitch").
|
||||
local initialPitch is hBox:AddTextField("85").
|
||||
|
||||
local hBox is interface:AddHBox().
|
||||
hBox:AddLabel("Gravity Turn @").
|
||||
local gravTurnStart is hBox:AddTextField("8000").
|
||||
|
||||
local hBox is interface:AddHBox().
|
||||
hBox:AddLabel("Gravity Pitch").
|
||||
local gravPitch is hBox:AddTextField("75").
|
||||
|
||||
local hBox is interface:AddHBox().
|
||||
hBox:AddLabel("Target Apoapsis").
|
||||
local targetApo is hBox:AddTextField("80000").
|
||||
|
||||
local launchButton is interface:AddButton("Launch").
|
||||
set launchButton:onClick to launchButtonPressed@.
|
||||
|
||||
interface:show().
|
||||
|
||||
wait until false.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue