Lv.1
作者不懒,但还是没有留下任何个性签名
在 【贪吃蛇教程】那么多类的贪吃蛇玩法,你知道吗? 中回复
不——————
这对一个python大佬极其不友好因为我只会用python做贪吃蛇而这个发不了python文件
啊啊啊啊啊啊啊啊啊啊啊啊啊啊啊啊啊啊啊啊啊啊
2021-01-31T12:51:25 点赞:1
在 一起制作源码图鉴 中回复
还可以加上数据,比如编程猫
血量:80 攻击:80 防御:80
特攻:80 特防:80 速度:80
大家可以按编程猫的数据模板做调整
2021-04-05T19:03:57 点赞:0
在 【Python作品分享】【去太空,趣编程】3D星空 中回复
更新一下:
from turtle import * from random import random, randint screen = Screen() width, height = 800, 600 screen.setup(width, height) screen.title("模拟星空") screen.bgcolor("black") screen.mode("logo") screen.delay(0) t = Turtle(visible=False, shape='circle') t.pencolor("yellow") t.fillcolor("yellow") t.penup() t.setheading(-90) t.goto(width/2, randint(-height/2, height/2)) stars = [] for i in range(200): star = t.clone() s = random() / 3 star.shapesize(s, s) star.speed(int(s*10)) star.setx(width/2 + randint(1, width)) star.sety(randint(-height/2, height/2)) star.showturtle() stars.append(star) while True: for star in stars: star.setx(star.xcor() - 3 * star.speed()) if star.xcor() < -width/2: star.hideturtle() star.setx(width/2 + randint(1, width)) star.sety(randint(-height/2, height/2)) star.showturtle()2021-05-02T19:12:08 点赞:0