Code Sketch
Christmas Tree
Category: Art
cleari
setBackground(Color(255, 207, 145))
def shape3 = Picture{
right(135)
forward(70.71)
right(90)
forward(70.71)
right(90)
forward(70.71)
right(90)
forward(70.71)
right(90)
}.thatsStrokeColored(black)
def shape4 = Picture{
right()
forward(100)
left(135)
forward(70.71)
left(90)
forward(70.71)
}.thatsStrokeColored(black)
def shape1 = Picture{
right(135)
forward(141.42)
left(135)
forward(200)
left(135)
forward(141.42)
}.thatsStrokeColored(black)
def shape5 = Picture{
left(45)
forward(70.71)
left(135)
forward(100)
left(135)
forward(70.71)
}.thatsStrokeColored(black)
def shape6 = Picture{
forward(100)
right(135)
forward(70.71)
right(45)
forward(100)
right(135)
forward(70.71)
}.thatsStrokeColored(black)
def shape7 = Picture {
left(45)
forward(141.42)
left(135)
forward(100)
left(90)
forward(100)
}.thatsStrokeColored(black)
def tree = picStack(
Picture {},
shape3.thatsStrokeColored(Color(30, 149, 34)).thatsFilledWith(Color(30, 149, 3)).withFlippedX.thatsRotated(-45).thatsTranslated(35, 70),
shape5.thatsStrokeColored(Color(152, 15, 135)).thatsFilledWith(Color(65, 231, 109)).thatsRotated(90).thatsTranslated(50, 170),
shape5.thatsStrokeColored(Color(235, 129, 15)).thatsFilledWith(Color(71, 133, 35)).withFlippedX.thatsRotated(90).thatsTranslated(0, 120),
shape1.thatsStrokeColored(Color(183, 59, 59)).thatsFilledWith(Color(88, 229, 64)).withFlippedX.thatsRotated(90).thatsTranslated(-50, 170),
shape1.thatsStrokeColored(yellow).thatsFilledWith(green).withFlippedX.thatsRotated(90).thatsTranslated(0, 270),
shape6.thatsStrokeColored(Color(33, 162, 39)).thatsFilledWith(Color(33, 202, 31)).withFlippedX.thatsRotated(90).thatsTranslated(100, 120),
shape7.thatsStrokeColored(Color(0, 228, 235)).thatsFilledWith(Color(28, 208, 42)).thatsRotated(-135).thatsTranslated(-70.71, 270),
)
tree.draw