赞
踩
本文目录:
用pythoin turtle海龟绘制《巴斯光年》卡通人物形象,起源于一位网友,他喜欢《巴斯光年》,问我能不能画出来,我没答应他,只是说有时间时试试看,因为我也是刚接触python turtle海龟绘图不久的,并不是高手。我并不确认自己能够画出复杂配件的人物形象,网上的例子也都是偏于简单线条色块的熊猫、叮当、小黄人之类。
最近,这位小弟弟再次问我画得怎样,看来他是真的喜欢《巴斯光年》,还很有礼貌地称呼我姐姐,于是我决定再尝试一下。画了好久。
纠正一下,我是姐姐,但我是很老很老的姐姐(奶奶级别的)。
通过pythoin turtle海龟绘制卡通人物,让我感触比较深的一点:不要轻易抱怨困难有多大,你尽力了吗?
前段时间,我原创绘制的”草莓熊“在抖音和其他平台被大量转载(我也是偶然才发现怎么到处都是我画的草莓熊?)。很多程序员总是纠结自己年龄大了,还能不能继续编程工作。我个人觉得:定律归定律,但关键在于你自己。
我不是程序员,我只是一个平凡得不能再平凡的普通人,又老身体也不太好,也不是养尊处优之辈,家里有老人,煮饭洗碗之类一般人需要做的家务事,我也需要动手处理。我老了,身体也不好,不能胜任高强度的工作,但如果我努力,我也还能做一些自己想做的事情。。。如果我能办到的事情,其他人也一定能同样做到。所以,如果你遇到任何困难,请不要轻易放弃初衷,纵然不能如愿,也需尽力而为,这样过完一生才无悔。
请尊重原创的不易,转载需保留作者所有相关信息。
中文名称: | 巴斯光年 |
英文名称: | Buzz Lightyear。 |
角色: | 是1995年迪士尼公司和皮克斯动画工作室公司共同合作的玩具总动员中的主角之一。角色中他是一名未来太空人。 |
性格: | 理智,自信,单纯,果断,勇猛,随和,幽默,有责任心和正义感,关心伙伴。自认为是远方星际的领袖,一心想要拯救地球,飞向宇宙。他是勇敢的探险家,一个勇于自我牺牲的人物。 |
弱点: | 一旦打开氧气罩就会呼吸困难(玩具总动员1时胡迪掀开氧气罩时,以为自己不能呼吸,将要死去,后来知道自己是玩具后便克服此弱点。 |
技能: | 激光(按右臂的按钮后,红灯就会发声发亮,借以吓唬别人)。 |
装备: | 通讯器(左臂安装着通讯器); 喷气装置,按左胸上的红色圆形按钮,背部的飞行器就会自动打开。 |
巴斯光年给人的形象一直都是比较勇敢,他有着无所畏惧的勇气,这也是无论大人或者小朋友都非常羡慕和喜爱它的一个原因。
巴斯光年曾经说过:
一个人一生可以爱上很多的人,等你获得真正属于你的幸福之后,你就会明白一起的伤痛其实是一种财富,它让你学会更好地去把握和珍惜你爱的人。
《巴斯光年》歌手:谢霆锋
作词 : 黄伟文
作曲 : 胡波
侵略者马上发动进攻
要紧急出发到外太空
跑道的最后却踏个空
跌一交的痛哪及我心痛
在童年一讲起我的志愿
要做个星空保卫队救地球
到了今天至知
多想振翅宇宙里遨游
人天生得一对手
作个最坏的准备
但是向著最高最远星体出发
如果真的不会飞
试试跌下的滋味
落地以后以双脚去继续历奇
人间的风景也很美
不用找降伞放入背包
纵使我将会继续跌交
当梦想破灭化做气泡
半空中都算发射过一炮
在童年一讲起我的志愿
要做个星空保卫队救地球
到了今天至知
多想振翅宇宙里遨游
人天生得一对手
作个最坏的准备
但是向著最高最远星体出发
如果真的不会飞
试试跌下的滋味
落地以后以双脚去继续历奇
人间的风景也很美
醒过来 来 就从谷底再出发
醒过来 来 别人间蒸发
我有个最坏的准备
但是向著最高最远星体出发
如果真的不会飞
试试跌下的滋味
梦幻破灭也不放弃更是传奇
谁都阻不到我跟你
醒过来 来 就从谷底再出发
醒过来 来 做人好多个玩法
将源代码完整拷贝,保存成:你的文件名.py ,(记得保存时文件编码格式选UTF-8,保存类型选所有文件(*.*),后缀一定要用.py)。例如:BuzzLightyear.py然后在python环境下运行。你会看到和我一样的《巴斯光年》效果。
代码的语法解释部分,可点击查看文章里的介绍:草莓熊python turtle绘图代码(玫瑰花版)附源代码
只要你正确安装配置了python环境,都可以运行我写的《巴斯光年python turtle绘图_附源代码》。将源代码完整拷贝,保存成:你的文件名.py,例如:BuzzLightyear.py,然后在python环境下运行。你会看到和我一样的《巴斯光年》效果。
如果你只想看看巴斯光年绘图动画,正确安装配置了python环境后,直接用记事本也行。
1、检查你的python配置,配置好python运行环境变量
2、打开巴斯光年python turtle绘图__附源代码_逆境清醒的博客-CSDN博客文章页面,拉动到“源代码”具体内容部分,复制全部源代码
3、打开记事本,粘贴代码,把文件另存为:你的文件名.py(记得保存时文件编码格式选UTF-8,保存类型选所有文件(*.*),后缀一定要用.py)。例如:BuzzLightyear.py
4、电脑win+R运行cmd命令→进入命令行状态—→进入你放巴斯光年代码的目录。
5、如果你的操作系统是win10以上,可先在文件资源管理器中打开你放巴斯光年代码的目录,然后在空白处直接右键选:在终端中打开,(此时会自动进入你放巴斯光年代码的目录)
6、使用命令:python(空格)BuzzLightyear.py
如果操作没有出错,这时应该能够看到绘制巴斯光年过程的动画
建议有时间还是学一下python 海龟绘图的基本知识,这样你就可以自己绘制一些喜欢的图画。绘制完,你还可以将你的动画打包发给朋友,和他(她)一起分享其中的乐趣和快乐。
Python脚本不能在没有安装Python的机器上运行。
这个时候可以将脚本打包成exe文件,发送给别人,即使他(她)电脑上没有安装Python解释器,这个exe程序也能在上面运行。方法:安装Pyinstaller。
同时按window+R键,输入cmd,打开命令提示符窗口,
输入:pip install pyinstaller
(可以按自己网络情况切换使用国内源来加速,例如:
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple pyinstaller
pip install -i https://pypi.douban.com/simple/ pyinstaller
等等)
例如安装最新版的pyinstaller v5.6.2
1、复制全部源代码,打开记事本,粘贴代码,把文件另存为:你的文件名.py(记得保存时文件编码格式选UTF-8,保存类型选所有文件(*.*),后缀一定要用.py)。例如:BuzzLightyear.py
2、准备好.ico文件(如果你需要自己定义可执行文件所显示的图标图案时),将.ico文件保存到和.py文件同一个目录里。
这里因为不能直接上传显示.ico文件,我将资源图片提供给大家,大家自己制作一下。可以用ps或在线工具,例如:https://app.xunjiepdf.com/img2icon/
.ico文件只能是:16*16,20*20,24*24,32*32,48*48,64*64,128*128,256*256像素,不要弄错了呀,要不然,1、ps等工具不给你保存.ico文件的选项,2、无法正常让程序显示指定.ico。3、。。。你要不要拼一下你的人品?哈哈~
3、同时按window+R键,输入cmd,打开命令提示符窗口,
输入:Pyinstaller -F -w -i ico256.ico BuzzLightyear.py
功能:将指定的BuzzLightyear.py文件打包成可执行exe文件,并使用指定的图标
具体解释可参考下文“Pyinstaller参数详解”部分
执行完后,文件夹里会多出来 build 和 dist 两个文件夹,
进入dist 文件夹,里面就有我们需要的.exe可执行文件。
点击运行BuzzLightyear.exe文件,出现动画:
现在,你可以将BuzzLightyear.exe文件发给你的朋友,和他一起分享乐趣了。
(其他你自己写的python文件一样可以这样处理喔,^_^)
v5.6.2
- #-*- coding: UTF-8 -*-
- import turtle as t
-
- """
- =================================================
- @Project ->Adversity Awake 巴斯光年系列
- @类别 : 巴斯光年->巴斯光年之1
- @Author : 逆境清醒
- @Date : 2022/12/2 04:02
- @Desc :https://blog.csdn.net/weixin_69553582
- =================================================
- """
- # 设置背景颜色,窗口位置以及大小
-
- t.colormode(255)# 颜色模式
- t.speed(0)
- t.screensize(900,900,"white")#画布大小背景颜色
- t.setup(width=900, height=900,startx=None, starty=None)#绘图窗口的大小和起始坐标
- t.title("逆境清醒巴斯光年!")#设置绘图窗口的标题
- t.resizemode('noresize') #大小调整模式:auto,user,noresize
- t.tracer(1)
- t.hideturtle()
-
-
-
-
-
-
- def mlingpen(x, y):
- t.penup()
- t.goto(x, y)
- t.pendown()
-
- def mlingfacecheek(x, y, fx):
- mlingpen(x, y)
- t.seth(fx)
- t.pencolor("#fcd1ae")
- t.fillcolor('#fcd1ae')
- t.begin_fill()
- n = 1.8
- for i in range(120):
- if 0 <= i < 30 or 60 <= i < 90:
- n -= 0.05
- t.left(3)
- t.fd(n)
- else:
- n += 0.05
- t.left(3)
- t.fd(n)
- t.end_fill()
-
- def mlingfacecheek_h(x, y, fx):
- mlingpen(x, y)
- t.seth(fx)
- t.pencolor("#fcc6ae")
- t.fillcolor('#fcc6ae')
- t.begin_fill()
- n = 1.6
- for i in range(120):
- if 0 <= i < 30 or 60 <= i < 90:
- n -= 0.06
- t.left(3)
- t.fd(n)
- else:
- n += 0.06
- t.left(3)
- t.fd(n)
- t.end_fill()
-
- def mlingzuanzhou1(x, y, fx):
- mlingpen(x, y)
- t.seth(fx)
- t.pencolor("#2f2f33")
- t.fillcolor('#a0a9ae')
- t.begin_fill()
- n = 1.8
- for i in range(120):
- if 0 <= i < 30 or 60 <= i < 90:
- n -= 0.05
- t.left(3)
- t.fd(n)
- else:
- n += 0.05
- t.left(3)
- t.fd(n)
- t.end_fill()
-
- def mlingellipse(x,y,jiajiao,l, size,color1,color2):
- mlingpen(x, y)
- t.seth(jiajiao + 270)
- t.pensize(size)
- t.pencolor(color1)
- t.fillcolor(color2)
- t.pendown()
- t.begin_fill()
- a = 0.3
- for i in range(120):
- if 0 <= i < 30 or 60 <= i < 90:
- a += l
- t.lt(3)
- t.fd(a)
- else:
- a -= l
- t.lt(3)
- t.fd(a)
- t.penup()
- t.end_fill()
-
- def mlingrotate_left(chishu, angle, length):
- for i in range(chishu):
- t.left(angle)
- t.forward(length)
-
- def mlingrotate_right(chishu, angle, length):
- for i in range(chishu):
- t.right(angle)
- t.forward(length)
-
- def bsgnface():
- t.pensize(2)
- t.pencolor("#622300")
- t.fillcolor('#fdd7a4')
- t.begin_fill()
- mlingpen(-80,0)
- t.seth(150)
- t.circle(-50,60)
- t.seth(90)
- mlingrotate_right(10,2,10)
- t.circle(-70,38)
- t.goto(-60,210)
- t.goto(-40,205)
- t.goto(20,165)
- t.right(40)
- t.circle(-70,98)
- mlingrotate_right(10,5,13)
- t.circle(-64,71)
- t.goto(-80,0)
- t.end_fill()
- #AdversityAwake
- t.pensize(1)
- t.pencolor("#fcdbae")
- t.fillcolor('#fcdbae')
- t.begin_fill()
- mlingpen(-80,0)
- t.seth(150)
- t.circle(-50,60)
- t.seth(90)
- mlingrotate_right(10,2,10)
- t.circle(-70,38)
- t.goto(-60,210)
- t.goto(-40,205)
- t.goto(20,165)
- t.right(40)
- t.circle(-60,98)
- mlingrotate_right(10,5,13)
- t.circle(-64,71)
- t.goto(-80,0)
- t.end_fill()
-
- mlingellipse(-40,130,100,0.06,2,'#58302b','#ffffff')
- mlingellipse(-10,123,-10,0.06,2,'#58302b','#ffffff')
-
- t.seth(0)
- mlingpen(-42,145)
- t.pensize(3)
- t.pencolor("#362d2e")
- t.fillcolor('#3c7ec3')
- t.begin_fill()
- t.circle(13,360)
- t.end_fill()
- mlingpen(-40,154)
- t.fillcolor('#362d2e')
- t.begin_fill()
- t.circle(4,360)
- t.end_fill()
- #AdversityAwake
- t.seth(0)
- mlingpen(20,110)
- t.pensize(3)
- t.pencolor("#362d2e")
- t.fillcolor('#3c7ec3')
- t.begin_fill()
- t.circle(13,360)
- t.end_fill()
- mlingpen(20,120)
- t.fillcolor('#362d2e')
- t.begin_fill()
- t.circle(4,360)
- t.end_fill()
- #AdversityAwake
- t.seth(0)
- mlingpen(-47,166)
- t.pensize(1)
- t.pencolor("#ffffff")
- t.fillcolor('#ffffff')
- t.begin_fill()
- t.circle(2,360)
- t.end_fill()
- #AdversityAwake
- t.seth(0)
- mlingpen(12,126)
- t.pensize(1)
- t.pencolor("#ffffff")
- t.fillcolor('#ffffff')
- t.begin_fill()
- t.circle(2,360)
- t.end_fill()
- #AdversityAwake
- t.seth(0)
- mlingpen(-22,158)
- t.pensize(2)
- t.pencolor("#622300")
- t.fillcolor('#622300')
- t.begin_fill()
- t.goto(-50,200)
- t.left(100)
- t.circle(8,180)
- t.goto(-60,180)
- t.left(210)
- t.circle(-5,180)
- t.goto(-22,150)
- t.goto(-22,158)
- t.end_fill()
- mlingpen(-15,158)
- t.pensize(2)
- t.pencolor("#622300")
- t.fillcolor('#622300')
- t.begin_fill()
- t.circle(40,70)
- t.circle(-20,180)
- t.right(100)
- t.circle(30,50)
- t.left(30)
- mlingrotate_left(5,-5,5)
- mlingrotate_left(5,-1,4)
- t.goto(-15,158)
- t.end_fill()
- #AdversityAwake
- t.seth(180)
- mlingpen(-20,80)
- t.pensize(3)
- t.pencolor("#d1966b")
- t.fillcolor('#fccc8b')
- t.begin_fill()
- t.circle(-60,30)
- t.circle(-10,75)
- t.right(20)
- mlingrotate_right(5,2,9)
- t.circle(22,65)
- t.pu()
- t.end_fill()
- t.seth(60)
- t.pensize(5)
- mlingpen(-45,98)
- t.pencolor("#f8dbc4")
- mlingrotate_right(5,2,8)
- t.seth(-95)
- t.pensize(2)
- mlingpen(-70,96)
- t.pencolor("#652500")
- t.fillcolor('#652500')
- t.begin_fill()
- t.circle(40,30)
- t.seth(-40)
- t.pensize(1)
- t.pencolor("#652500")
- t.circle(70,40)
- t.circle(30,40)
- t.circle(2,180)
- t.circle(-30,40)
- t.right(2)
- t.circle(-70,40)
- t.end_fill()
- t.seth(0)
- t.pensize(3)
- mlingpen(-42,208)
- t.pencolor("#000000")
- t.fillcolor('#6b3f8d')
- t.begin_fill()
- t.circle(-30,60)
- t.circle(50,60)
- t.circle(-30,110)
- t.circle(50,60)
- t.circle(-30,60)
- t.circle(5,180)
- mlingrotate_left(5,1,20)
- t.circle(80,150)
- t.goto(-42,208)
- t.end_fill()
- t.pensize(1)
- mlingpen(-85,15)
- t.circle(-6,200)
- t.left(3)
- t.circle(-4,200)
- t.left(3)
- t.circle(-2,200)
-
- def saihong(x,y,r):
- t.pensize(1)
- t.pencolor("#fcc6ae")
- t.fillcolor('#fcc6ae')
- t.begin_fill()
- mlingpen(x,y)
- t.circle(r,360)
- t.end_fill()
-
- def bsgntoukui():
- t.pensize(2)
- t.pencolor("#000000")
- t.fillcolor('#dadada')
- t.begin_fill()
- mlingpen(250,40)
- t.seth(80)
- t.circle(240,60)
- t.circle(200,40)
- t.circle(250,35)
- t.circle(228,225)
- t.end_fill()
- #AdversityAwake
- t.pensize(3)
- t.pencolor("#5b5c5e")
- t.fillcolor('#948e92')
- t.begin_fill()
- mlingpen(160,-20)
- t.seth(60)
- t.circle(180,50)
- t.circle(200,50)
- t.circle(190,35)
- t.left(8)
- t.circle(160,50)
- t.right(5)
- t.circle(210,15)
- t.right(90)
- t.fd(15)
- t.right(90)
- t.circle(-210,15)
- t.left(8)
- t.circle(-160,50)
- t.right(3)
- t.circle(-190,35)
- t.circle(-210,50)
- t.circle(-210,60)
- t.right(90)
- t.fd(15)
- t.goto(160,-20)
- t.end_fill()
- #AdversityAwake
- t.pensize(3)
- t.pencolor("#32384c")
- t.fillcolor('#7d6a6d')
- t.begin_fill()
- mlingpen(220,20)
- t.seth(80)
- t.circle(180,50)
- t.circle(280,50)
- t.circle(190,20)
- t.left(2)
- t.circle(125,65)
- t.right(90)
- t.fd(15)
- t.right(90)
- t.circle(-135,60)
- t.left(1)
- t.circle(-145,10)
- t.circle(-220,30)
- t.circle(-320,30)
- t.circle(-210,55)
- t.right(90)
- t.fd(15)
- t.goto(220,20)
- t.end_fill()
-
- mlingellipse(-195,43,-5,0.50,3,'#37363d','#37363d')
- mlingellipse(-230,40,80,0.13,3,'#76828e','#a0a9ae')
- mlingellipse(-220,40,80,0.13,3,'#a0a9ae','#393843')
- mlingellipse(-210,45,80,0.11,3,'#6a6776','#6a6776')
- mlingellipse(-198,45,80,0.11,3,'#52445c','#5e5763')
- mlingellipse(-190,40,80,0.09,3,'#a0a9ae','#a0a9ae')
- mlingellipse(-176,40,80,0.09,3,'#55535d','#393843')
-
-
- t.seth(0)
- t.pensize(3)
- t.pencolor("#32384c")
- t.fillcolor('#7d6a6d')
- t.begin_fill()
- mlingpen(220,80)
- t.end_fill()
-
-
- #def bsgnyifu():
-
- t.seth(180)
- t.pensize(3)
- t.pencolor("#000000")
- t.fillcolor('#ffffff')
- t.begin_fill()
- mlingpen(-330,40)
- t.fd(25)
- t.circle(30,80)
- t.circle(250,30)
- t.circle(30,130)
- t.goto(-330,40)
- t.end_fill()
-
- t.seth(180)
- t.pensize(3)
- t.pencolor("#000000")
- t.fillcolor('#000000')
- t.begin_fill()
- mlingpen(-285,55)
- t.fd(20)
- t.circle(30,70)
- t.circle(250,35)
- t.circle(30,130)
- t.left(57)
- t.circle(-250,40)
- t.goto(-285,55)
- t.end_fill()
- t.seth(0)
- t.pensize(3)
- t.pencolor("#000000")
- t.fillcolor('#000000')
- t.begin_fill()
- mlingpen(-180,-280)
- t.goto(-180,-330)
- t.right(33)
- t.circle(300,65)
- t.goto(-180,-280)
- t.end_fill()
- t.seth(-90)
- t.pensize(3)
- t.pencolor("#000000")
- t.fillcolor('#ffffff')
- t.begin_fill()
- mlingpen(-280,-160)
- t.goto(-240,-270)
- t.goto(160,-350)
- t.goto(250,-240)
- t.goto(250,-90)
- t.goto(-280,-160)
- t.end_fill()
- t.seth(-100)
- t.pensize(3)
- t.pencolor("#51265d")
- t.fillcolor('#6b3f8d')
- t.begin_fill()
- mlingpen(250,-240)
- t.circle(-55,80)
- t.circle(-210,50)
- t.goto(0,-260)
- t.left(180)
- t.circle(210,50)
- t.left(10)
- t.circle(100,50)
- t.goto(250,-240)
- t.up()
- t.end_fill()
- t.seth(-100)
- t.begin_fill()
- mlingpen(-250,-180)
- t.goto(-280,-200)
- t.circle(40,85)
- t.goto(-200,-210)
- t.goto(-250,-180)
- t.end_fill()
- t.seth(160)
- t.pensize(3)
- t.pencolor("#000000")
- t.fillcolor('#000000')
- mlingpen(260,-260)
- t.begin_fill()
- t.circle(-80,60)
- t.right(20)
- t.circle(-280,35)
- t.circle(-80,70)
- t.right(61)
- t.circle(-280,60)
- t.goto(260,-260)
- t.end_fill()
-
-
- def bsgnyifushangyi():
- t.seth(60)
- t.pensize(3)
- mlingpen(-200,-10)
- t.pencolor("#51265d")
- t.fillcolor('#6b3f8d')
- t.begin_fill()
- t.circle(-150,40)
- t.circle(-285,70)
- t.right(90)
- t.circle(-300,85)
- t.goto(-200,-10)
- t.end_fill()
- #AdversityAwake
- t.seth(33)
- t.pensize(3)
- t.pencolor("#375502")
- t.fillcolor('#6ba812')
- t.begin_fill()
- mlingpen(-160,40)
- t.circle(-150,26)
- t.right(160)
- t.circle(50,73)
- t.right(-90)
- t.fd(10)
- t.goto(-100,-85)
- t.right(-145)
- t.circle(-150,40)
- t.circle(-43,77)
- t.goto(-160,40)
- t.up()
- t.end_fill()
- #AdversityAwake
- t.seth(8)
- t.begin_fill()
- mlingpen(-110,-10)
- t.circle(-150,45)
- t.goto(30,-20)
- t.goto(35,-35)
- t.goto(165,20)
- t.right(20)
- t.fd(90)
- t.right(83)
- t.circle(-280,69)
- t.goto(-110,-10)
- t.end_fill()
- t.pensize(3)
- mlingpen(30,-20)
- t.goto(-90,-90)
- mlingpen(30,-20)
- t.right(-135)
- t.fd(90)
-
-
-
- def mylinganniu(x,y,fx,yuan,fd1,color1,color2,color3,color4):
- t.seth(fx)
- t.pensize(3)
- t.pencolor(color1)
- t.fillcolor(color2)
- t.begin_fill()
- mlingpen(x,y)
- t.circle(-yuan,180)
- t.fd(fd1)
- t.circle(-yuan,180)
- t.fd(fd1)
- t.end_fill()
- mlingpen(x-8,y)
- t.pencolor(color3)
- t.fillcolor(color4)
- t.begin_fill()
- t.circle(-yuan,180)
- t.fd(fd1)
- t.circle(-yuan,180)
- t.fd(fd1)
- t.end_fill()
-
-
-
- def gsgnwaiyi():
- t.seth(-180)
- t.pensize(3)
- t.pencolor("#467602")
- t.fillcolor('#6ba812')
- t.begin_fill()
- mlingpen(-240,90)
- t.circle(50,60)
- t.circle(210,100)
- t.goto(-120,-230)
- t.goto(-50,-260)
- t.left(20)
- t.circle(330,35)
- t.left(2)
- t.circle(330,30)
- t.goto(320,70)
- t.goto(240,160)
- t.left(210)
- t.circle(-200,50)
- t.circle(-250,40)
- t.circle(-320,55)
- t.goto(-240,90)
- t.end_fill()
- #AdversityAwake
- t.seth(-100)
- t.pensize(3)
- t.pencolor("#ffffff")
- t.fillcolor('#ffffff')
- t.begin_fill()
- mlingpen(-164,-65)
- t.circle(280,15)
- t.circle(20,80)
- t.right(10)
- t.circle(310,12)
- t.circle(20,80)
- t.circle(-280,12)
- t.goto(-40,-95)
- t.goto(-164,-65)
- t.end_fill()
- #AdversityAwake
- t.seth(-100)
- t.pensize(3)
- t.pencolor("#7cc4df")
- t.fillcolor('#7cc4df')
- t.begin_fill()
- mlingpen(-155,-85)
- t.circle(280,10)
- t.circle(20,80)
- t.right(8)
- t.circle(310,9)
- t.circle(20,80)
- t.circle(-280,10)
- t.right(-85)
- t.circle(150,40)
- t.goto(-155,-85)
- t.end_fill()
- #AdversityAwake
- t.pencolor("#000000")
- mlingpen(-120,-120)
- t.goto(-150,-110)
- t.goto(-145,-140)
- t.goto(-130,-143)
- t.circle(3,190)
- t.goto(-120,-160)
- t.goto(-110,-153)
- t.right(60)
- t.circle(4,150)
- t.goto(-85,-153)
- t.goto(-65,-123)
- t.goto(-100,-123)
- t.goto(-110,-110)
- t.goto(-120,-120)
- mlingpen(-120,-127)
- t.goto(-145,-120)
- mlingpen(-120,-134)
- t.goto(-145,-127)
- mlingpen(-120,-141)
- t.goto(-145,-134)
- mlingpen(-108,-129)
- t.goto(-75,-130)
- mlingpen(-108,-136)
- t.goto(-77,-137)
- mlingpen(-108,-143)
- t.goto(-80,-144)
- mlingpen(-105,-110)
- t.write("SPACERANGER",align="center",font=("黑体",10,"normal"))
- t.seth(0)
- t.pensize(2)
- t.pencolor("#000000")
- t.fillcolor('#b5bf55')
- t.begin_fill()
- mlingpen(-40,-150)
- t.fd(120)
- t.left(90)
- t.fd(30)
- t.left(90)
- t.fd(120)
- t.left(90)
- t.fd(30)
- t.left(90)
- t.end_fill()
- mlingpen(20,-140)
- t.write("LIGHTYEAR.AA",align="center",font=("黑体",12,"normal"))
-
- t.seth(-130)
- t.pensize(3)
- t.pencolor("#375502")
- t.fillcolor('#375502')
- t.begin_fill()
- mlingpen(-240,90)
- t.circle(170,60)
- t.left(165)
- t.circle(-170,38)
- t.goto(-240,90)
- t.end_fill()
- t.seth(-120)
- mlingpen(-245,20)
- t.pensize(7)
- t.circle(35,80)
- t.right(2)
- t.circle(280,18)
- t.right(75)
- t.circle(280,15)
- t.circle(20,80)
- t.right(70)
- t.goto(-125,-170)
- t.goto(-125,-230)
- mlingpen(-115,-230)
- t.goto(-115,-170)
- t.left(70)
- t.fd(30)
- t.circle(20,80)
- t.circle(-280,12)
- t.right(75)
- t.circle(350,38)
- t.seth(0)
- t.pensize(3)
- mlingpen(200,-60)
- t.goto(80,-200)
-
-
-
- mlingellipse(-39,-190,0,0.1,2,'#97bf54','#97bf54')
- mlingellipse(-32,-190,0,0.08,2,'#520600','#a3020c')
- mlingellipse(-33,-190,0,0.07,2,'#d0272b','#cb0310')
- mylinganniu(-260,-100,90,10,50,'#001d29','#00417c','#2172cd','#005cc1')
- mylinganniu(-230,-120,90,10,50,'#002900','#11400c','#127b34','#438f51')
- mylinganniu(-200,-140,90,10,50,'#2d0f00','#800707','#e34441','#e0524b')
-
-
- def bsgnshou():
- t.seth(0)
- t.pensize(3)
- t.pencolor("#000000")
- t.fillcolor('#ffffff')
- t.begin_fill()
- mlingpen(215,-35)
- t.circle(36)
- t.end_fill()
- t.begin_fill()
- mlingpen(220,35)
- t.goto(200,80)
- t.goto(150,140)
- t.left(120)
- t.circle(20,90)
- t.left(-90)
- t.circle(20,50)
- t.left(-50)
- t.circle(100,60)
- t.circle(15,150)
- t.left(-50)
- t.circle(20,60)
- t.left(-50)
- t.circle(20,60)
- t.circle(-90,40)
- t.left(-50)
- t.circle(20,60)
- t.goto(110,50)
- t.goto(110,30)
- t.left(-150)
- t.circle(-90,40)
- t.circle(15,180)
- t.circle(110,70)
- t.left(-50)
- t.circle(50,30)
- t.goto(220,35)
- t.end_fill()
- t.seth(0)
- t.begin_fill()
- mlingpen(320,-200)
- t.goto(200,-75)
- t.left(120)
- t.circle(-20,80)
- t.fd(70)
- t.circle(-20,60)
- t.goto(370,-100)
- t.goto(320,-200)
- t.end_fill()
- t.seth(120)
- t.pencolor("#000000")
- t.fillcolor('#6b3f8d')
- t.begin_fill()
- mlingpen(150,140)
- t.circle(20,90)
- t.left(-90)
- t.circle(20,200)
- t.left(-50)
- t.circle(20,70)
- t.goto(150,140)
- t.end_fill()
- t.seth(160)
- mlingpen(22.23,207.02)
- t.begin_fill()
- t.circle(15,200)
- t.end_fill()
- t.left(-10)
- t.circle(-100,50)
- t.seth(130)
- mlingpen(56.68,60.78)
- t.begin_fill()
- t.circle(15,200)
- t.end_fill()
-
- def bsgnyifuhuibian():
- t.seth(90)
- t.pensize(3)
- t.pencolor("#696d7e")
- t.fillcolor('#838a95')
- t.begin_fill()
- mlingpen(-180,60)
- t.circle(23,155)
- t.circle(250,10)
- t.circle(50,60)
- t.circle(300,10)
- t.left(6)
- t.circle(330,10)
- t.circle(330,10)
- t.right(6)
-
- t.circle(350,65)
- t.circle(28,185)
- t.circle(-320,30)
- t.right(6)
- t.circle(-320,25)
- t.left(7)
- t.circle(-270,30)
- t.right(6)
- t.circle(-65,90)
- t.goto(-180,60)
- t.end_fill()
-
- t.pencolor("#696d7e")
- t.fillcolor('#696d7e')
- t.begin_fill()
- t.seth(90)
- t.circle(23,50)
- t.left(-270)
- t.circle(65,100)
- t.left(160)
- t.circle(-65,70)
- t.goto(-180,60)
- t.end_fill()
-
-
-
- t.pencolor("#003d78")
- t.penup()
- t.goto(390,145)
- t.pendown()
- t.write("拥\n有\n无\n所\n畏\n惧\n的\n勇\n气\n",align="center",font=("黑体",20,"normal"))
-
- mlingpen(350,215)
- t.write("逆\n境\n清\n醒\n愿\n你\n:\n",align="center",font=("黑体",16,"normal"))
-
-
-
-
- if __name__ == '__main__':
- t.seth(0)
- t.pensize(25)
- mlingpen(0,-380)
- t.pencolor("#000000")
- t.fillcolor('#b3e3f0')
- t.begin_fill()
- t.circle(380)
- t.end_fill()
- bsgntoukui()
- bsgnyifushangyi()
- bsgnface()
- mlingfacecheek(-55,125,90)
- saihong(-60,115,12)
- mlingfacecheek(18,66,10)
- saihong(10,68,12)
- #bsgnyifu()
- gsgnwaiyi()
- bsgnyifuhuibian()
- bsgnshou()
- t.seth(0)
- t.pensize(25)
- mlingpen(0,-380)
- t.pencolor("#000000")
- t.circle(380,720)
- t.done()
-
-
-
![](https://csdnimg.cn/release/blogv2/dist/pc/img/newCodeMoreWhite.png)
推荐阅读:
![]() | ||
| 2023年春节祝福第二弹——送你一只守护兔,让它温暖每一个你【html5 css3】画会动的小兔子 | |
25 | | 2023春节祝福系列第一弹(放飞祈福孔明灯,祝福大家身体健康)(附完整源代码及资源免费下载) |
24 |
| |
23 |
| |
22 |
| |
21 |
| python爱心源代码集锦 |
20 |
| 巴斯光年python turtle绘图__附源代码 |
19 |
| Three.js实例详解___旋转的精灵女孩(附完整代码和资源) |
18 |
| |
17 |
| |
16 |
| |
15 |
| |
14 |
| |
13 |
| |
12 |
| |
11 |
| 用代码写出浪漫__合集(python、matplotlib、Matlab、java绘制爱心、玫瑰花、前端特效玫瑰、爱心) |
10 |
| |
9 |
| |
8 |
| |
7 |
| |
6 |
| |
5 |
| |
4 |
| |
3 |
| |
2 |
| |
1 |
|
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。