Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- set steeringmanager:pitchtorquefactor to 0.2.
- set steeringmanager:yawtorquefactor to 0.5.
- set steeringmanager:rollcontrolanglerange to 180.
- steeringmanager:resetpids().
- lock x to 90.
- lock p to 5.
- set roll to 0.
- lock steering to heading(x,p,-roll).
- fuelcells on.
- set tweak to 0.
- lock deploy to max(3,airspeed^0.7) + tweak.
- lock torque to throttle * 100.
- set blades to ship:partsdubbedpattern("fanblade").
- set rotors to ship:modulesnamed("ModuleRoboticServoRotor").
- set bladeMods to list().
- For b in blades {
- set bmod to b:getmodule("ModuleControlSurface").
- bmod:setfield("deploy", true).
- bladeMods:add(bmod).
- }
- set adjust to true.
- when true then {
- set deploycopy to deploy.
- set torquecopy to torque.
- For b in bladeMods b:setfield("deploy angle", deploycopy).
- for rt in rotors rt:setfield("torque limit(%)", torquecopy).
- return adjust.
- }
- // /me when true then { set tcopy to min(ship:electriccharge-100, throttle)*100. for rt in rotors rt:setfield("torque limit(%)", tcopy ). return adjust. }
- set sgp to 0.
- set sggo to true.
- set sgf to 8.
- set sgpr to 4.
- function sgd {
- parameter l. parameter d.
- If l:length > sgpr set sgpr to l:length.
- print (l:padleft(sgpr) + ": " +round(d,2)):padright(terminal:width) at (0, sgp).
- set sgp to sgp + 1.
- }.
- lock twr to ship:availablethrust/ship:mass/body:mu*body:position:sqrmagnitude.
- set sggo to false. wait 0. set sggo to true.
- On round(kuniverse:realtime * sgf) {
- set sgp to 0.
- sgd("Vertical Speed", ship:verticalspeed).
- sgd("alt radar",alt:radar).
- sgd("groundspeed",groundspeed).
- sgd("twr",twr).
- sgd("oxidizer", ship:oxidizer).
- sgd("liquidfuel", ship:liquidfuel).
- sgd("eta minutes", alt:radar / -ship:verticalspeed / 60).
- sgd("electric charge", ship:electriccharge).
- Print "":padright(terminal:width) at (0,sgp).
- Set sgp to sgp + 1.
- sgd("tweak",tweak).
- sgd("deploy",deploy).
- sgd("torque limit(%)", torque).
- Print "":padright(terminal:width) at (0,sgp).
- Set sgp to sgp + 1.
- Print "":padright(terminal:width) at (0,sgp).
- return sggo.
- }
Add Comment
Please, Sign In to add comment