summaryrefslogtreecommitdiff
path: root/src/sliceitoff/__main__.py
blob: 17e7317ef6249848091605a8c2873f578190a30c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
""" Slice It Off! - Game where you slice the area where enemies reside to
    the minimum
"""

from time import sleep
from pathlib import Path

import pygame

from display import Display
from images import Images, Fonts
from game import Level


def sliceitoff():
    """ The game - It all starts here """
    pygame.init()

    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
    
    while level1.step(dt):
        dt = clock.tick()

    pygame.quit()

sliceitoff()