diff options
author | Viljami Ilola <+@hix.fi> | 2024-03-18 18:08:20 +0200 |
---|---|---|
committer | Viljami Ilola <+@hix.fi> | 2024-03-18 18:08:20 +0200 |
commit | 78704848d4459907a456044615714b59d4593b2f (patch) | |
tree | d56c8422793ff1c5b6554146980760d264a6a0fe /src/sliceitoff/__main__.py | |
parent | b219c4f736e6b98dd247064b362997576954f0ff (diff) |
stats, level_up, game_over
Diffstat (limited to 'src/sliceitoff/__main__.py')
-rw-r--r-- | src/sliceitoff/__main__.py | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/sliceitoff/__main__.py b/src/sliceitoff/__main__.py index 17e7317..4e5a626 100644 --- a/src/sliceitoff/__main__.py +++ b/src/sliceitoff/__main__.py @@ -10,24 +10,29 @@ import pygame from display import Display from images import Images, Fonts from game import Level +from stats import Stats def sliceitoff(): """ The game - It all starts here """ pygame.init() + + pygame.mouse.set_visible(False) display = Display() current_path = Path(__file__).parent.resolve() Images.load_images( current_path ) Fonts.load_fonts( current_path ) - level1 = Level(display = display, level = 10, score = 10) - clock = pygame.time.Clock() dt = 0 + + Stats.new_game() - while level1.step(dt): - dt = clock.tick() + while Stats.lives: + level = Level(display = display) + while level.step(dt): + dt = clock.tick() pygame.quit() |