Advertisement
jabela

10 Have Another Go

Dec 20th, 2015
302
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.52 KB | None | 0 0
  1. if rect2.colliderect(rect1) or car1.x<0 or car1.x>330:
  2.         window.fill((0, 0, 0))
  3.         fontprint("Game Over. You scored: "+str(score),10,200)
  4.         if score > hiscore:
  5.             hiscore = score
  6.             fontprint('You have a new high Score !!',10,250)
  7.         else:
  8.             fontprint("High Score: "+str(hiscore),10,250)
  9.  
  10.         pygame.display.update()
  11.         randx = random.randrange(0, 300)
  12.         randy = 0
  13.         marky = 600
  14.         score = 0
  15.         speed = 5
  16.         car1.x = 200
  17.         wait()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement