Commit 9e74b6df by BellCodeEditor

save project

parent 56f8e85d
Showing with 12 additions and 10 deletions
......@@ -44,7 +44,7 @@ hero = [pygame.image.load('hero1.png'),
#o=Block(stone,cacti,apple)
block_list=pygame.sprite.Group()
c
time=0
index = 0
JumpSpeed= 30
......@@ -53,9 +53,9 @@ road_x=0
background_x=0
word2=0
nub1=0
nub =0
nub =0
gamestate=True
old_score=word2
y = 400
while True:
......@@ -98,11 +98,13 @@ while True:
if index == 5:
index = 0
if old_score!=word2:
old_score=word2
score_music.play()
road_x-=8
if road_x==-1000:
speed=10+word2//3
road_x-=speed
if road_x<=-1000:
road_x=0
background_x-=2
if background_x==-1000:
......@@ -116,7 +118,7 @@ while True:
screen.blit(road, (road_x,500))
screen.blit(wukong.image, (150,y))
speed=8+word2//3
time+=1
if time==50:
time=0
......@@ -142,9 +144,9 @@ while True:
scoreWord=word.render(info+str(word2),True,(255,255,255))
screen.blit(scoreWord, (730,10))
pygame.mixer. mmznz
pygame.display.update()
FPS.tick(60)
FPS.tick(80)
......
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