#def armor #def target #def heat #def heading #def accuracy ; set settings int 3 opo 17 6 opo 13 opo 18 :1 opo 11 100 opo 14 10 ipo 2 heat ; get heat ipo 6 armor ; get armor ipo 3 heading ; get heading cmp heat 100 ja 1 ; if heat is high restart cmp armor 20 jb 2000 ; if critical set overburn opo 17 6 :2 ipo 7 target cmp target 5000 ja 3 ; if no target found, go to scanning subroutine call 1000 :3 jmp 1 :1000 ipo 8 accuracy cmp accuracy ja 1002 jb 1003 opo 13 do 5 :1001 opo 15 loop 1001 ret :1002 opo 13 opo 15 4 ret :1003 opo 13 opo 15 -4 ret jmp 1 :2000 int 4 int jmp 1 #END