导语
"月色暗淡还有星辰—山河失色你还有我"
——《告白文案》
🎠1个月就要跨入2022年了,编也没有什么拿得出手的🎁礼物
所以我准备了很多很多的告白小故事+表白的小程序送给大家,单身的你可以好好学习下🎃🎃
希望能在你们撩妹撩汉的时候好好运用起来~
提供参考:源码基地在主页左侧(pc端)拿源码素材哈免费!
正文
本文是由Turtle写的多份源码项目啦!需要源码滴滴我即可~
一、第一份:俗话说的好,我爱你。
1)☽小文案☽
你知道吗?在我的世界观念里,我希望都有你的存在,因为你在我的世界里对于我而言是那么的重要。
You know what? In my view of the world, I hope you exist, because you are so important to me in my world.
2)主程序
import turtle
import time# 画心形圆弧def hart_arc():for i in range(200):turtle.right(1)turtle.forward(2)def move_pen_position(x, y):turtle.hideturtle() # 隐藏画笔(先)turtle.up() # 提笔turtle.goto(x, y) # 移动画笔到指定起始坐标(窗口中心为0,0)turtle.down() # 下笔turtle.showturtle() # 显示画笔# 初始化turtle.setup(width=800, height=500) # 窗口(画布)大小turtle.color('black', 'red') # 画笔颜色turtle.pensize(1) # 画笔粗细turtle.speed(1) # 描绘速度# 初始化画笔起始坐标move_pen_position(x=0,y=-180) # 移动画笔位置turtle.left(140) # 向左旋转140度turtle.begin_fill() # 标记背景填充位置# 画心形直线( 左下方 )
turtle.forward(224) # 向前移动画笔,长度为224# 画爱心圆弧hart_arc() # 左侧圆弧
turtle.left(120) # 调整画笔角度
hart_arc() # 右侧圆弧# 画心形直线( 右下方 )turtle.forward(224)turtle.end_fill() # 标记背景填充结束位置# 点击窗口关闭程序window = turtle.Screen()window.exitonclick()
3)效果展示
二、第二份:年少的欢喜是你。
1)☽小文案☽
是的,你的每一次夸奖都在我的心里画上了浓重的一笔,我可以肆无忌惮的去对待任何人,但我却不能肆无忌惮地对待你
Yes, every time you praise me, I draw a heavy stroke in my heart. I can treat anyone without fear, but I can't
treat you without fear
2)主程序
import turtle as t
from time import sleep
def go_to(x, y):t.up()t.goto(x, y)t.down()
def head(x, y, r):go_to(x, y)t.speed(20)t.circle(r)leg(x, y)
def leg(x, y):t.right(90)t.forward(180)t.right(30)t.forward(100)t.left(120)go_to(x, y - 180)t.forward(100)t.right(120)t.forward(100)t.left(120)hand(x, y)
def hand(x, y):go_to(x, y - 60)t.forward(100)t.left(60)t.forward(100)go_to(x, y - 90)t.right(60)t.forward(100)t.right(60)t.forward(100)t.left(60)eye(x, y)
def eye(x, y):go_to(x - 50, y + 130)t.right(90)t.forward(50)go_to(x + 40, y + 130)t.forward(50)t.left(90)
def big_Circle(size):t.speed(20)for i in range(150):t.forward(size)t.right(0.3)
def line(size):t.speed(20)t.forward(51 * size)
def small_Circle(size):t.speed(20)for i in range(210):t.forward(size)t.right(0.786)
def heart(x, y, size):go_to(x, y)t.left(150)t.begin_fill()line(size)big_Circle(size)small_Circle(size)t.left(120)small_Circle(size)big_Circle(size)line(size)t.end_fill()
def main():t.pensize(2)t.color('pink', 'red')head(-120, 100, 100)heart(250, -80, 1)go_to(100, -300)t.write("To: 年少的欢喜是你", move=True, align="left", font=("楷体", 20, "normal"))t.done()
main()
3)展示效果
三、第三份:上面的升级版。
1)☽小文案☽
如果我逐日一追求你的时候,我会被风吹向大海,因为大海的深蓝才可以表达我对你爱意的真相。恋爱时,我不要只和
你谈风花雪月,我还要和你谈未来,因为我希望你所有的计划当中都把我包含其中。
If I pursue you day by day, I will be blown to the sea by the wind, because the deep blue of the sea can
express the truth of my love for you. When I'm in love, I don't just want to talk about romance with you, I
also want to talk about the future with you, because I hope all your plans include me.
2)展示效果
Part 01 你的爱心已接收。完整的项目源码见小编主页(PC端)左侧免费领取!
四、第四份:
1)☽小文案☽
我都觉得你成为了我的光,因为你让我的人间都换了岁月,所以有些东西一干一开始就应该保持原有的模样,比如爱
情,我需要扮演好你最想变成的那个角色
I feel that you have become my light, because you have changed the years in my world, so some things should keep their original appearance from the beginning, such as love, I need to play the role you want to be
然后在你需要我的时候突然出现,这并不代表着与爱无关,它恰恰变成了平淡岁月里的柴米油盐,你知道吗?
Then you suddenly appear when you need me, which doesn't mean it has nothing to do with love, it just becomes the daily necessities in the plain years, you know?
2)主程序
#画左边的小人
turtle.goto(-600,-200)
turtle.goto(-600,-120)
turtle.circle(35)
turtle.goto(-600,-200)
turtle.forward(40)
turtle.right(90)
turtle.forward(60)
turtle.hideturtle()
turtle.up()
turtle.goto(-600, -160)
turtle.down()
turtle.showturtle()
turtle.left(90)
turtle.forward(55)
turtle.right(45)
turtle.forward(20)
turtle.hideturtle()
turtle.up()
turtle.goto(-600, -145)
turtle.down()
turtle.showturtle()
turtle.goto(-545, -145)
turtle.left(90)
turtle.forward(20)#画第一个爱心
turtle.color('pink', 'pink')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-500, -153)
turtle.down()
turtle.showturtle()
turtle.right(90)
turtle.forward(30)
turtle.left(90)
turtle.forward(30)
turtle.left(45)
turtle.circle(10.6,180)
turtle.left(180)
turtle.circle(10.6,180)
turtle.end_fill()
#下一个大爱心
turtle.color('green', 'green')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-430, -143)
turtle.down()
turtle.showturtle()
turtle.left(135)
turtle.right(90)
turtle.forward(50)
turtle.left(90)
turtle.forward(50)
turtle.left(45)
turtle.circle(17.67,180)
turtle.left(180)
turtle.circle(17.67,180)
turtle.end_fill() #第三个爱心
turtle.color('red', 'red')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-315, -133)
turtle.down()
turtle.showturtle()
turtle.left(135)
turtle.right(90)
turtle.forward(70)
turtle.left(90)
turtle.forward(70)
turtle.left(45)
turtle.circle(24.74,180)
turtle.left(180)
turtle.circle(24.74,180)
turtle.end_fill() #第四个爱心
turtle.color('red', 'red')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-187, -133)
turtle.down()
turtle.showturtle()
turtle.left(135)
turtle.right(90)
turtle.forward(70)
turtle.left(90)
turtle.forward(70)
turtle.left(45)
turtle.circle(24.74,180)
turtle.left(180)
turtle.circle(24.74,180)
turtle.end_fill()#第5个爱心
turtle.color('green', 'green')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-43.7, -143)
turtle.down()
turtle.showturtle()
turtle.left(135)
turtle.right(90)
turtle.forward(50)
turtle.left(90)
turtle.forward(50)
turtle.left(45)
turtle.circle(17.67,180)
turtle.left(180)
turtle.circle(17.67,180)
turtle.end_fill() #第6个爱心
turtle.color('pink', 'pink')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(53.88, -153)
turtle.down()
turtle.showturtle()
turtle.right(90)
turtle.right(225)
turtle.forward(30)
turtle.left(90)
turtle.forward(30)
turtle.left(45)
turtle.circle(10.6,180)
turtle.left(180)
turtle.circle(10.6,180)
turtle.end_fill() #画右边的小人
turtle.hideturtle()
turtle.up()
turtle.goto(251.28, -255)
turtle.down()
turtle.showturtle()
turtle.goto(196.28,-200)
turtle.goto(196.28,-120)
turtle.left(90)
turtle.circle(35)
turtle.goto(196.28,-200)
turtle.left(180)
turtle.forward(40)
turtle.left(90)
turtle.forward(60)
turtle.hideturtle()
turtle.up()
turtle.goto(196.28,-160)
turtle.down()
turtle.showturtle()
turtle.right(90)
turtle.forward(55)
turtle.left(45)
turtle.forward(20)
turtle.hideturtle()
turtle.up()
turtle.goto(196.28, -145)
turtle.down()
turtle.showturtle()
turtle.right(45)
turtle.forward(55)
turtle.right(45)
turtle.forward(20)#画气球线和气球
#第一个气球
turtle.hideturtle()
turtle.up()
turtle.goto(-265, -133)
turtle.down()
turtle.showturtle()
turtle.goto(-245, 0)
turtle.right(135)
turtle.circle(35)
#第2个气球
turtle.hideturtle()
turtle.up()
turtle.goto(-265, -133)
turtle.down()
turtle.showturtle()
turtle.goto(-305, 80)
turtle.circle(40)
#第3个气球
turtle.hideturtle()
turtle.up()
turtle.goto(-137, -133)
turtle.down()
turtle.showturtle()
turtle.goto(-167, 0)
turtle.circle(35)
#第4一个气球
turtle.hideturtle()
turtle.up()
turtle.goto(-137, -133)
turtle.down()
turtle.showturtle()
turtle.goto(-117, 80)
turtle.circle(40)
#写字LOVE
turtle.pencolor("GREEN")
turtle.penup()
turtle.goto(-245,10)
turtle.write("人",move=False,align='center',font=("微软雅黑",30,'normal'))turtle.pencolor("PURPLE")
turtle.penup()
turtle.goto(-305,90)
turtle.write("间",move=False,align='center',font=("微软雅黑",30,'normal'))turtle.pencolor("YELLOW")
turtle.penup()
turtle.goto(-167,10)
turtle.write("清",move=False,align='center',font=("微软雅黑",30,'normal'))turtle.pencolor("ORANGE")
turtle.penup()
turtle.goto(-117, 90)
turtle.write("欢",move=False,align='center',font=("微软雅黑",30,'normal'))
3)展示效果
总结
看完这些表白文案,各位是不是迫不及待想恋爱了?由衷地祝愿,每一句情话终有主,每一个灵魂都不孤独。源码基地见啦各位~
呃,那啥,昨天医生说我有低血糖,需要几句甜蜜的话,大家看着办吧,评论区意思意思就行了哈。
源码基地——
滴滴我即可啦!看我主页(pc端也可以自取滴)~
🎉往期推荐阅读——
项目1.7 恋爱纪念日
【Python纪念册】一屋两人三餐四季:“距离百年好合只剩xx年了~“多少?进来看看就知道了。
项目1.8 故宫,下雪了
【故宫,下雪了】一夜醒来,故宫完成秋冬交接,来自北方的故事纷纷踏雪而来(内含多份源码)
项目1.3 视频播放器
用了都说好的Python专属无广告视频播放器,良心到想为它疯狂打call
项目3.2 自动换壁纸
【Python高级技能】超炫酷,电脑每天自动换壁纸,这个神器适合你。
🎄文章汇总——
项目1.0 Python—2021 |已有文章汇总 | 持续更新,直接看这篇就够了
(更多内容+源码都在文章汇总哦!!欢迎阅读~)