用python畫的蠟筆小新

代碼內(nèi)容如下:
這里要導入一個turtle庫,關于此庫的函數(shù)用法在本站的北京理工大學嵩天老師python課程的第二章里有所介紹,在此不一一贅述。
import turtle as t
t.setup(650,300,200,200)
t.pu()
t.fd(250)
t.seth(90)
t.pd()
t.pensize(10)
t.pencolor('black')
#臉部輪廓
t.begin_fill()
t.color('moccasin')
t.circle(200,180)
t.seth(-180)
t.circle(100,180)
t.fd(50)
t.circle(500,40)
#畫耳朵
t.seth(-90)
t.circle(55,45)
t.seth(90)
t.seth(30)
t.fd(45)
t.seth(360)
t.circle(55,255)
t.end_fill()
#畫嘴巴
t.pu()
t.goto(-120,-100)
t.pensize(1)
t.begin_fill()
t.color('red')
t.circle(35,360)
t.end_fill()
#畫左眼
t.goto(-75,50)
t.begin_fill()
t.color('black')
t.pd()
t.circle(35,360)
t.end_fill()
#畫左眼眼白
t.goto(-65,50)
t.begin_fill()
t.color('white')
t.circle(16.5,360)
t.end_fill()
#右眼
t.pu()
t.goto(45,50)
t.begin_fill()
t.color('black')
t.pd()
t.circle(35,360)
t.end_fill()
#畫右眼眼白
t.goto(55,50)
t.begin_fill()
t.color('white')
t.circle(16.5,360)
t.end_fill()
#畫眉毛
t.pu()
t.seth(90)
t.goto(5,70)
t.pensize(1)
t.pencolor('black')
t.pd()
t.circle(45,180)
t.pu()
t.seth(90)
t.goto(5,110)
t.pensize(15)
t.pencolor('black')
t.pd()
t.circle(45,180)
t.pu()
t.seth(90)
t.goto(125,70)
t.pensize(1)
t.pencolor('black')
t.pd()
t.circle(45,180)
t.pu()
t.seth(90)
t.goto(125,110)
t.pensize(15)
t.pencolor('black')
t.pd()
t.circle(45,180)
#畫頭發(fā)
t.pu()
t.goto(255,25)
t.seth(90)
t.pd()
t.pensize(10)
t.begin_fill()
t.color('black')
t.circle(200,120)
t.seth(-15)
t.fd(280)
t.seth(-90)
t.fd(100)
t.seth(360)
t.fd(25)
t.end_fill()
個人感覺還是有所欠缺,因此還希望大佬多多指正!