資源簡介
代碼片段和文件信息
#Drawcat?畫多啦一夢
from?turtle?import?*
#?無軌跡跳躍
def?my_goto(x?y):
????penup()
????goto(x?y)
????pendown()
#?眼睛
def?eyes():
????tracer(False)
????a?=?2.5
????for?i?in?range(120):
????????if?0?<=?i?30?or?60?<=?i?90:
????????????a?-=?0.05
????????????lt(3)
????????????fd(a)
????????else:
????????????a?+=?0.05
????????????lt(3)
????????????fd(a)
????tracer(True)
#?胡須
def?beard():
????my_goto(-37?135)
????seth(165)
????fd(60)
????my_goto(-37?125)
????seth(180)
????fd(60)
????my_goto(-37?115)
????seth(193)
????fd(60)
????my_goto(37?135)
????seth(15)
????fd(60)
????my_goto(37?125)
????seth(0)
????fd(60)
????my_goto(37?115)
????seth(-13)
????fd(60)
#?嘴巴
def?mouth():
????my_goto(5?148)
????seth(270)
????fd(100)
????seth(0)
????circle(120?50)
????seth(230)
????circle(-120?100)
#?圍巾
def?scarf():
????fillcolor(‘#e70010‘)
????begin_fill()
????seth(0)
????fd(200)
????circle(-5?90)
????fd(10)
????circle(-5?90)
????fd(207)
????circle(-5?90)
????fd(10)
????circle(-5?90)
????en
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2018-05-09?11:22??Draw-master\
?????文件????????4421??2018-05-09?11:22??Draw-master\Drawcat.py
?????文件????????3753??2018-05-09?11:22??Draw-master\Drawpig.py
- 上一篇:python 計算猴子吃桃問題
- 下一篇:電賽電磁炮python程序(sensor)
評論
共有 條評論