Commit 6d6ea55a by BellCodeEditor

auto save

parent 75fbb4de
Showing with 45 additions and 22 deletions
++ "b/i\343\200\202py"
import pygame
from pygame import locals
# 初始化pygame,为使用pygame做准备
pygame.init()
p=pygame.image.load('bg.png')
l=pygame.image.load('right.png')
b=pygame.image.load('body.png')
o=pygame.image.load('apple.png')
# 创建一个窗口
s=pygame.display.set_mode((800,600))
while True:
for event in pygame.event.get():
# # p=int(input('请输入半径:'))
# # o=p*2
# # z=o*3.14
# # m=p*(z/2)
# # print('直径:'+str(o))
# # print('周长:'+str(z))
# # print('面积:'+str(
import turtle
p=turtle.Pen()
a=int(input())
if event.type==locals.QUIT:
exit()
s.blit(p,(0,0))
s.blit(l,(240,120))
s.blit(b,(210,120))
s.blit(b,(180,120))
s.blit(b,(180,90))
s.blit(o,(360,300))
pygame.display.update()
\ No newline at end of file
# p.speed(0)
# p.fillcolor('blue')
# p.pu()
# p.goto(0,-200)
# p.pd()
# p.circle(200)
# p.pu()
# p.goto(-100,50)
# p.pd()
# p.begin_fill()
# p.circle(20)
# p.end_fill()
# p.pu()
# p.goto(100,50)
# p.pd()
# p.begin_fill()
# p.circle(20)
# p.end_fill()
# p.pu()
# p.goto(0,50)
# p.pd()
# p.circle(-50,steps=3)
# p.pu()
# p.goto(-150,-70)
# p.pd()
# p.goto(0,-170)
# p.goto(150,-70)
# turtle.done()
p.left(90)
p.fd(a)
p.left(60)
p.fd(a/2)
turtle.done()
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment