forked from Thaccus/Starbase-Nav-Suite
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFixerID_Nav_Modded.yolol
More file actions
22 lines (20 loc) · 1.01 KB
/
FixerID_Nav_Modded.yolol
File metadata and controls
22 lines (20 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
if :nav<1 then g=0 f=0 goto1 end
l=0.1 pt=7 yt=20 rt=-5 ep=1.05 ed=3000 et=3000 chill=15
if g>0 then :aas=1 else :aas=0 end
xD=:wx-:X yD=:wy-:Y zD=:wz-:Z Dt=sqrt((xD)^2+(yD)^2+(zD)^2)
if f<1 then x0=:x y0=:y z0=:z Do=Dt f=1 r=0 end
da=sqrt((:X-x0)^2+(:Y-y0)^2+(:Z-z0)^2) d0=d1 d1=Dt v1=d0-d1
dx=(Do-da)*ep+ed if Dt>dx then s=1 :c=0 end
if s>0 then :fwd=0 if abs(v1)<15 then f=0 g=0 s=0 goto1 end end
n="\n" :dd=(Do-da)+n+Dt+"\nly:"+:ly+" lx:"+:lx+" l:"+l+" g:"+g
if Dt<et then :nav=0 :fwd=0 :CRUS=100 end if g>0 then goto1 end
lx=(:lx>-l)*(:lx<l) ly=(:ly>-l)*(:ly<l) lz=:lz>0 a=0
if lx*ly*lz theng=1 :FWD=100 :CRUS=0 goto1end
if :ly<-l or :ly>l or 1-lz then :PCH=:ly*pt+pt*(:lz<0) end
if :lx<-l or :lx>l then :YAW=:lx*yt end
if :lz<-l or :lz>l then :ROL=:lz*rt end
if a<chill then a+=1 goto16end goto1
//line7 replacement if you want to stop+reoreint on AAS
//dx=(Do-da)*ep+ed if Dt>dx or :c>0 then s=1 :c=0 end
//tips to Fixerid.
//Requires compassDelta's Lxyz(Local wp orientation vector) data to work