Skip to content

Commit

Permalink
Ensure the variables are used as floats by default
Browse files Browse the repository at this point in the history
  • Loading branch information
erilyth committed Jan 16, 2017
1 parent 1817734 commit 7ed5762
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions flappy.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
from keras.optimizers import SGD

FPS = 30
SCREENWIDTH = 288
SCREENHEIGHT = 512
SCREENWIDTH = 288.0
SCREENHEIGHT = 512.0
# amount by which base can maximum shift to left
PIPEGAPSIZE = 100 # gap between upper and lower part of pipe
BASEY = SCREENHEIGHT * 0.79
Expand Down Expand Up @@ -127,7 +127,7 @@ def main():
global SCREEN, FPSCLOCK
pygame.init()
FPSCLOCK = pygame.time.Clock()
SCREEN = pygame.display.set_mode((SCREENWIDTH, SCREENHEIGHT))
SCREEN = pygame.display.set_mode((int(SCREENWIDTH), int(SCREENHEIGHT)))
pygame.display.set_caption('Flappy Bird')

# numbers sprites for score display
Expand Down

0 comments on commit 7ed5762

Please sign in to comment.