Shelf: Convert post_height to variable, echo post_height.
This commit is contained in:
parent
39a7014c89
commit
5b0d1ef276
@ -30,6 +30,11 @@ lath_depth = 4.8; /* y */
|
||||
|
||||
board_height = 1.6; /* z */
|
||||
|
||||
post_height = drawers_begin + (drawer_size * drawers_number)
|
||||
+ (board_height * drawers_number + board_height);
|
||||
|
||||
echo("Post height is", post_height);
|
||||
|
||||
module drawer()
|
||||
{
|
||||
/* Sides */
|
||||
@ -92,8 +97,6 @@ module lath(length)
|
||||
|
||||
module shelf()
|
||||
{
|
||||
function post_height() = drawers_begin + (drawer_size * drawers_number)
|
||||
+ (board_height * drawers_number + board_height);
|
||||
/* Posts */
|
||||
color("olive")
|
||||
{
|
||||
@ -103,7 +106,7 @@ module shelf()
|
||||
{
|
||||
translate([x, y, 0])
|
||||
{
|
||||
lath(post_height());
|
||||
lath(post_height);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -128,7 +131,7 @@ module shelf()
|
||||
|
||||
/* Top */
|
||||
translate(
|
||||
[x, drawer_size - lath_depth, post_height() - lath_depth - 10])
|
||||
[x, drawer_size - lath_depth, post_height - lath_depth - 10])
|
||||
{
|
||||
rotate([90, 0, 0])
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user