-
Notifications
You must be signed in to change notification settings - Fork 0
/
stairs.scad
145 lines (124 loc) · 2.29 KB
/
stairs.scad
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
module stairs_up() {
cube([36,36,7]);
f1 = 36;
f3 = 7;
for(i=[0:5]) {
x = f1 + i * 11;
z = f3 + i * 7;
translate([x,0,z]) {
cube([11,36,7]);
}
}
translate([102, 0, 49]) {
cube([36,36,7]);
}
translate([102, -11, 56]) {
cube([36,11,7]);
}
}
module ground_floor() {
cube([36,36,7]);
f1 = 36;
f3 = 7;
for(i=[0:5]) {
x = f1 + i * 11;
z = f3 + i * 7;
translate([x,0,z]) {
cube([11,36,7]);
}
}
translate([102, 0, 49]) {
cube([36,36,7]);
}
translate([102, -45, 63]) {
cube([36,36,7]);
}
f4 = 91;
f6 = 70;
for(i=[0:5]) {
p = f4 - i * 11;
q = f6 + i * 7;
translate([p, -45, q]) {
cube([11, 36, 7]);
}
}
translate([0, -45, 112]) {
cube([36,36,7]);
}
translate([0, -11, -7]) {
cube([36,11,7]);
}
translate([102, -11, 56]) {
cube([36,11,7]);
}
}
module ground_walls() {
//side - wall
rotate([90,0,0]) {
translate([0, -126, -36]) {
color("lightgrey", 0.7) square([138,370]);
}
}
rotate([90,0,90]) {
translate([-207, -126, 0]) {
//color("lightgrey", 0.5) square([243,370]);
}
}
//ground - ceiling
translate([0, -207, 119]) {
//color("lightblue", 0.3) square([138, 160]);
}
//ground - floor
translate([0, -207, -7]) {
//color("lightblue", 0.3) square([102, 207]);
}
translate([0, -207, -7]) {
color("lightblue", 0.3) square([138, 157]);
}
//first - ceiling
translate([0, -207, 245]) {
//color("lightblue", 0.3) square([138, 160]);
}
//base - floor
translate([0, -207, -126]) {
color("lightblue", 0.3) square([138, 160]);
}
}
module sample() {
cube([36,36,7]);
}
module translate_ground() {
translate([0, 0, 126]) {
color("blue") ground_floor();
}
}
module translate_stairs_up() {
translate([0, 0, -84]) {
color("lightgreen") stairs_up();
}
m = 11;
n = 91;
for(i=[0:5]) {
p = -(m + i * 11);
q = -(n + i * 7);
translate([0, p, q]) {
color("lightgreen") cube([36,11,7]);
}
}
}
module body() {
translate([100,-50,-14]) {
//color("red", 0.8) cube([24, 12, 72]);
}
}
module ground_stair_clearance() {
translate([102, -47, -21]) {
color("lightgreen") cube([36,36,7]);
}
}
body();
ground_floor();
ground_walls();
translate_ground();
translate_stairs_up();
ground_stair_clearance();