-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdraw.ks
28 lines (23 loc) · 873 Bytes
/
draw.ks
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
RUNONCEPATH("0:/utility.ks").
function drawNavballDirection {
parameter navballDirection.
parameter label.
drawDirection(heading_direction(navballDirection), label).
}
function drawDirection {
parameter direction.
parameter label.
parameter startingVector IS V(0,0,0).
LOCAL runwayForeVector TO VECDRAW(startingVector, direction:FOREVECTOR*30, RGB(1,0,0),label + ".F",1.0, TRUE, 0.2).
LOCAL runwayStarVector TO VECDRAW(startingVector, direction:STARVECTOR*30, RGB(0,1,0),label + ".S",1.0, TRUE, 0.2).
LOCAL runwayTopVector TO VECDRAW(startingVector, direction:TOPVECTOR*30, RGB(0,0,1),label + ".T",1.0, TRUE, 0.2).
}
function drawVector {
parameter endingVector.
parameter label.
parameter startingVector IS V(0,0,0).
LOCAL drawnVector TO VECDRAW(startingVector, endingVector, RGB(1,0,0), label, 1.0, TRUE, 0.2).
}
function erase {
CLEARVECDRAWS().
}