Code Sketch


DIWALI
By: Sanjay kumar
Category: Art
clear()
setSpeed(fast)
val cb = canvasBounds
val clr = cm.radialGradient(
0, 0, red,
cb.height / 4,yellow,
true
)
setBackground(clr)
setPenColor(black)
setFillColor(green)
setSpeed(superFast)
hop(15)
right(45)
forward(100)
right(45)
forward(250)
right(45)
forward(100)
right(135)
forward(250)
right(45)
forward(90)
left()
forward(90)
right(45)
forward(15)
hop(-100)
right()
hop(25)
circle(20)
hop(-27)
setFillColor(magenta)
right()
hop(-95)
repeat(2){
    forward(375)
    right()
    forward(225)
    right()
    }
repeat(2){
    forward(140)
    right()
    forward(225)
    right()
   }
right()
hop(225)
left()
hop(35)
setPenColor(black)
setFillColor(blue)
repeat(2){
    forward(70)
    left()
    forward(180)
    left()
}
hop(175)
left()
hop(60)
repeat(4){
    forward(120)
    right()
    }
hop(60)
right()
forward(120)
hop(-60)
left()
hop(-60) 
forward(120)
hop(80)
left()
hop(400)
left()
repeat(2){
setFillColor(brown)
setPenColor(brown)
right(180,100)
right(120)
left(100,69)
right(140)
left(100,69)
hop(-110)
    left(62)
    hop(90)
    setFillColor(yellow)
    setPenColor(yellow)
    right(28)
    left(45,150)
    left(135)
    left(45,150)
    right(22)
hop(180)
left()
hop(220)
right(88)
}
hop(-450)
setPenColor(black)
circle(40)
left(90)
hop(10)
right(88)
circle(30)
left(80)
hop(30)
setFillColor(red)
circle(10)
right()
right(180)
hop(-25)
forward(60)
left()
hop(100)
setFillColor(yellow)
circle(60)
left(90)
hop(10)
right(88)
circle(50)
left(80)
hop(30)
repeat(2){
    setFillColor(purple)
forward(50)
left()
forward(25)
left()
}
right()
hop(-15)
right()
forward(10)
hop(-25)
right()
hop(-55)
forward(100)
right(72)
hop(30)
right(180)
write("DO  NOT  USE  CRACKER ")
left()
hop(260)
setFillColor(yellow)
left()
circle(70)
left(90)
hop(10)
right(88)
circle(60)
left(80)
hop(40)
setFillColor(green)
repeat(3){
forward(50)
left(120)
}
left(45)
hop(-40)
forward(120)
hop(-250)
left(52)
setPenColor(white)
repeat(2){
write("HAPPY")
hop(-20)
write("DIWALI")
hop(-120)
right()
hop(115)
left()
}