Identical lightning images striking a point at the same time. The graphic is enhanced by sharp bends on lightning images.
Feel free to copy the basic Python Turtle code that is given below. Don't hesitate to ask questions about the code if you have any. Enjoy! Please comment, like, or subscribe :)
Incidentally, for manually colorable graphics and variations, please visit my author site at https://www.amazon.com/author/basicpy...
import turtle
t = turtle.Turtle() #Definitions and Initializations
screen = turtle.Screen()
t.pensize(4)
lightning_size = 88 #Changeable to a number close to 88; Length of line segment from graphic center to point of bend
def lightning(x): #Procedure for drawing a lightning with size x = lightning_size
t.color("purple") #Changeble color
t.fillcolor() #Start of filling procedure with color indicated in t.color
t.begin_fill()
t.forward(0.5 * x)
t.right(150)
t.forward(x * 3 ** 0.5) #Turtle movement over a side of a 30-60-90 triangle (Please see structure of graphic.)
t.right(90)
t.forward(x)
t.left(60)
t.forward(x)
t.right(165)
t.forward(x)
t.right(60)
t.forward(x)
t.left(90)
t.forward(x * 3 ** 0.5) #Turtle movement over a side of a 30-60-90 triangle (Please see structure of graphic.)
t.end_fill() #End of fill procedure with automatic connection between starting and ending points
t.penup() #Python_Graphic start of drawing procedure
for i in range(12): #Loop to draw 12 lightning images
t.setheading(90 + i * 30) #Turtle rotation to current lightning to be drawn
t.forward(2.5 * lightning_size) #Trail-less movement of turtle to starting point of lightning drawing
t.pendown() #Start of lightning drawing
lightning(lightning_size) #Function call to draw a lightning with indicated size
t.penup() #Preparation for trail-less movement of turtle to draw next lightning
t.home()
t.hideturtle()
screen.exitonclick()