$fn = 64; // --- Parameters --- width = 60; // Overall width of the tower total_depth = 70; // Total depth including the tray tower_depth = 45; // Depth of the tower section height = 100; // Total height of the tower wall = 3; // Wall thickness corner_r = 6; // Radius for the tray's front corners tray_depth = total_depth - tower_depth; union() { difference() { // --- Main Body Outer --- union() { // Tower Body cube([width, tower_depth, height]); // Dice Catch Tray hull() { translate([0, tower_depth - 0.1, 0]) cube([width, 0.1, 15]); translate([corner_r, total_depth - corner_r, 0]) cylinder(r=corner_r, h=15); translate([width - corner_r, total_depth - corner_r, 0]) cylinder(r=corner_r, h=15); } } // --- Inner Cavities (Hollowing) --- // Tower Inner Cavity translate([wall, wall, wall]) cube([width - 2*wall, tower_depth - 2*wall, height]); // Tray Inner Cavity hull() { translate([wall, tower_depth - 0.2, wall]) cube([width - 2*wall, 0.1, 15]); translate([corner_r, total_depth - corner_r, wall]) cylinder(r=corner_r - wall, h=15); translate([width - corner_r, total_depth - corner_r, wall]) cylinder(r=corner_r - wall, h=15); } // Exit Hole (Connects Tower to Tray) translate([wall, tower_depth - wall - 0.1, wall]) cube([width - 2*wall, wall + 0.2, 28]); // Top Drop Notch (Easier dice insertion) translate([wall, tower_depth - wall - 0.1, height - 15]) cube([width - 2*wall, wall + 0.2, 16]); } // --- Internal Baffles --- // Note: Baffles overlap into the walls by 1mm/0.5mm to ensure manifold geometry // Baffle 1 (Top, angled back to front) translate([wall - 1, wall - 0.5, height - 10]) rotate([-45, 0, 0]) cube([width - 2*wall + 2, 28, wall]); // Baffle 2 (Middle, angled front to back) translate([wall - 1, tower_depth - wall + 0.5, height - 35]) rotate([225, 0, 0]) cube([width - 2*wall + 2, 28, wall]); // Baffle 3 (Bottom ramp guiding dice to the exit) hull() { translate([wall - 1, wall - 0.5, 40]) cube([width - 2*wall + 2, 1, wall]); translate([wall - 1, tower_depth - wall - 0.5, wall]) cube([width - 2*wall + 2, 1, wall]); } }