-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlampplate
More file actions
49 lines (40 loc) · 1.18 KB
/
lampplate
File metadata and controls
49 lines (40 loc) · 1.18 KB
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
def LampPlate(x as Number y as Number
width as Number
height as Number
tick_width as Number) = {
def dent = 20
def tick_depth = 10
def bot_width = width * 0.5
def top_width = width * 0.5
def fin_height = height * 0.8
def bump(sx as Number sy as Number
width as Number
topWidth as Number
height as Number ) = {
def space = width - topWidth
def bx = sx + height
def by = sy + space * 0.5
def cx = sx + height
def cy = sy + (space * 0.5) + topWidth
def dx = sx
def dy = sy + width
line(sx sy bx by)
line(bx by cx cy)
line(cx cy dx dy)
}
line(x y bot_width + x y)
line(bot_width + x y width + x fin_height + y)
line(width + x fin_height + y top_width + x height + y)
line(x + width * 0.5 y + height x + 20 y + height)
line(x y x y + height * 0.1)
bump(x y + height * 0.1 30 15 dent)
bump(x + 20
(y + (height * 0.1) + (30 * 0.5) - (tick_width * 0.5))
tick_width tick_width tick_depth)
line(x y + 50 x y + 100)
line(x y + 100 x + dent y + 120)
line(x + dent y + 120 x + dent y + 160)
bump(x + dent y + 160 tick_width tick_width tick_depth)
line(x + dent y + 163 x + dent y + height)
}
LampPlate(10 10 100 200 3)