Commit 887074b7 by BellCodeEditor

save project

parent 95b66d29
Showing with 3 additions and 3 deletions
import pygame
from pygame import locals
from pygame.time import Clock as TIME
pygame.init() # 初始化
# 创建一个窗口
screen = pygame.display.set_mode((1000, 600))
pygame.display.set_caption("悟空酷跑 * v8.03.67683 *")
TIME = pygame.time.Clock() # pygame时钟,控制游戏速度(帧数)
# 载入图片
background = pygame.image.load('bg.png') # 背景
road_img = pygame.image.load('road.png') # 路
......@@ -50,4 +50,4 @@ while True:
screen.blit(hero, (150, y))
# 刷新画面
pygame.display.update()
TIME.tick(60)
\ No newline at end of file
TIME().tick(60)
\ 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