DECLARE PARAMETER useRCS is FALSE. CLEARSCREEN. //Script init RCS ON. SET ship:control:pilotmainthrottle to 0. SET faerdig to 0. //Acquire node and prepare SET knude to nextnode. SET maks_acc to ship:maxthrust/ship:mass. SET burn_tid to knude:deltav:mag/maks_acc. PRINT "Script initiation at " + round(burn_tid/120,2) + " min.". //Node target and approach WAIT UNTIL knude:eta <= (burn_tid/2 + 60). LOCK steering to knude:deltav. //WAIT UNTIL abs(knude_retning:direction:pitch - facing:pitch) < 0.15 and abs(knude_retning:direction:yaw - facing:yaw) < 0.15. WHEN knude:eta <= (burn_tid/2 + 5) then { //Fuel SETtle and engine ignition SET ship:control:fore to 1. WAIT 5. LOCK throttle to 1. WAIT 1. IF (useRCS = FALSE){ SET ship:control:fore to 0. } } //Stop condition WHEN knude:deltav:mag < 1 THEN { SET ship:control:fore to 0. LOCK throttle to 0. UNLOCK steering. UNLOCK throttle. WAIT 1. SET faerdig to 1. } //Holding loop and node clean-up UNTIL faerdig = 1 {} remove knude. PRINT "Burn complete.". RCS OFF.