Compare commits

...

2 Commits

Author SHA1 Message Date
mbhatti4
e7fa4e9eb7 Submit 2:
Here i wrote the fucntion for the body. I first positioned myself on the canvas where i wanted to start drawing and then called the oval function to draw it out.

I am struggling to get the program to draw. I don't think there is any errors in my code, as it is farily simple, but when i run it, it justdraws a weird shape.
2025-10-05 16:47:35 -04:00
mbhatti4
f4eb78122a My first submit:
I started with making the two main functions I will need for my drawing, which is an oval and wings.
For the wings, I used the oval fucntion in it. I will be also using the oval function to draw. the body of the butterfly,

I got stuck with just starting the project. Im not sure why it felt very overwhelming for me.
Seeing the examples, I do not think I am fluent enough in python to make it animate.
After reading super turtle library, it confused me more and made me nervous to start.
After taking some time away from the project, I decided to come back with idea of just drawing.
I think now that I have my two intial functiosn done, the rest of the project should be less overwhelming and I should be able to enjoy getting it done.
2025-10-05 16:38:56 -04:00
2 changed files with 38 additions and 4 deletions

View File

@@ -12,9 +12,9 @@ I will be making a butterfly fluttering its wings. The view will be from the fro
(Include your planning here, including your project milestone.) (Include your planning here, including your project milestone.)
### Milestone 1 ### Milestone 1
Create function for the most used shapes in the project. This will include an oval, rectangle and triangle function. I will also have a fly fucntion that will help when i begin drawing.
### Milestone 2 ### Milestone 2
Create background. I want to have a solid color background.
### Milestone 3 ### Milestone 3

View File

@@ -1,7 +1,41 @@
# drawing.py # drawing.py
# ---------- # ----------
# By ____(you)___________ # By Mishaal
# #
# (Briefly describe what this program does.) # The program draws a butterfly
from turtle import * from turtle import *
from turtle import forward, right
from superturtle.movement import fly, no_delay
fly(-150, 150)
with no_delay():
for i in range(720):
forward(300)
right(71)
def draw_oval(width, height, color):
fillcolor(color)
begin_fill()
for i in range(2):
circle(width, 90)
circle(height, 90)
end_fill()
def draw_wing(x, y, width, height, color, angle):
penup()
goto(x, y)
setheading(angle)
pendown()
draw_oval(t, width, height, color)
def draw_body():
penup()
goto(0,-100)
setheading(90)
pendown()
draw_oval(10,45,"black")
input()