/Bike/BoxRepair.foocad

I have a heavy duty plastic box, that has a few cracks in the reinforcment ribs. I will glue these parts over the crack, making it strong again.
class BoxRepair : AbstractModel() {
@Custom
var innerRadius = 30
@Custom
var width = 10
@Custom
var cornerLess = 2
@Custom
var thickness = 0.9
@Custom
var length = 40
@Piece
fun corner() : Shape3d {
val outerRadius = innerRadius + width
val profile = (Circle( outerRadius ) - Circle( innerRadius )) intersection
Square( outerRadius + 10 ).translate( cornerLess, cornerLess )
return profile.extrude( thickness )
}
@Piece
fun straight() = Cube( width, length, thickness )
override fun build() : Shape3d {
return corner() + straight().rightTo(0)
}
}
