Code
c = circle(r=150, fill='#341118')
show(c)
def square(color, side):
return rectangle(w=side, h=side, fill=color, stroke='none')
white_layer = square(side=212.5,color='#FEFDF3') | repeat(10, rotate(10))
yellow_layer = square(side=196, color='#F8E63D') | rotate(5) | repeat(10, rotate(10))
dark_yellow_layer = square(side=182, color='#E3BD36') | repeat(10, rotate(10))
orange_layer = square(side=168, color='#F36636') | rotate(5) | repeat(10, rotate(10))
red_layer = square(side=155, color='#a92822') | repeat(10, rotate(10))
show(white_layer,yellow_layer, dark_yellow_layer, orange_layer,red_layer)
middle_c = circle(r=97, fill='#6e962d')
white_layer = square(side=136,color='#FEFDF3') | repeat(3, rotate(30))
pink_layer = square(side=123,color='#E65A99') | repeat(3, rotate(30))
red_layer = square(side=105,color='#AE2924') | repeat(3, rotate(30))
green_layer = square(side=85,color='#212306') | repeat(5, rotate(30))
p1 = point(x=-20, y=0)
p2 = point(x=20, y=0)
p3 = point(x=0, y=95)
triangle_ring = polygon([p1, p2, p3], fill='#F36636') + ellipse(w=6, h=15, x=0, y=65, fill='#F8E63D') | repeat(12, rotate(30))
show(middle_c, white_layer, pink_layer, red_layer,triangle_ring, green_layer)
def inner_box_ring():
shape = rectangle(h=12, w=17, fill='#E3BD36', y=-32, stroke='none')
for i in range(1, 13) :
if i % 2 == 0:
shape = shape + rectangle(h=12, w=17, fill='#E3BD36', y=-32, stroke='none') | rotate(30)
else:
shape = shape + rectangle(h=12, w=17, fill='#36a810', y=-32, stroke='none') | rotate(30)
return shape
inner_c = circle(r=50, fill='#F8E63D') + circle(r=26, fill='#ff4102')+inner_box_ring()
inner_button = circle(r=13, fill='#ffffff', stroke_width=3) + tinkerhub_logo()
inner_line_ring = line(x1=13, y1=0, x2=50, y2=0, stroke_width=3) | repeat(12, rotate(30)) | rotate(15)
show(inner_c,inner_button, inner_line_ring)