Commit 621a444e by BellCodeEditor

save project

parent 7b377be8
Showing with 6 additions and 2 deletions
......@@ -27,12 +27,16 @@ hero = [pygame.image.load('hero1.png'),
pygame.image.load('hero3.png'),
pygame.image.load('hero4.png'),
pygame.image.load('hero5.png')]
score_audio = pygame.mixer.Sound('score.wav')
basic_font = pygame.font.Font('STKAITI.TTF')
index = 0
y = 400
jumpState = "runing"
t = 30
gamestate = True
time = 0
score = 0
old_score = score
#obstacle = Block([bush, stone, cacti])
block_list = pygame.sprite.Group()
while True:
......@@ -44,7 +48,7 @@ while True:
if jumpState == "runing":
if event.key == locals.K_SPACE:
jumpState = "up"
if gamestate = True:
if jumpState == "up": # 起跳状态
if t > 0:
y -= t
......
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