Advertisement
sumguytwitches

edc4 flight code

Oct 20th, 2020
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. set x to 90.
  2. set p to 0.
  3. set a to 2.
  4. set talt to 300.
  5. lock steering to heading(x,p).
  6. lock deploy to max(3,airspeed^0.7).
  7. lock tilt to max(75,min(90,alt:radar*90/talt)).
  8. set blades to ship:partsdubbedpattern("blade").
  9. Set servos to ship:partsdubbedpattern("servo").
  10. for rotor in ship:partsdubbedpattern("rotor") rotor:getmodulebyindex(1):setfield("torque limit(%)",100).
  11.  
  12.  
  13. set adjust to true.
  14. when true then {
  15. For b in blades b:getmodule("ModuleControlSurface"):setfield("deploy angle",deploy).
  16. For s in servos s:getmodule("ModuleRoboticRotationServo"):setfield("target angle",tilt).
  17. return adjust.
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement