33 lines
593 B
Python
33 lines
593 B
Python
import pygame
|
|
|
|
from Engine.Game import Game
|
|
|
|
WIN = pygame.display.set_mode((800, 800))
|
|
FPS = 60
|
|
|
|
|
|
def main():
|
|
run = True
|
|
clock = pygame.time.Clock()
|
|
game = Game(WIN)
|
|
|
|
while run:
|
|
pygame.init()
|
|
clock.tick(FPS)
|
|
|
|
for event in pygame.event.get():
|
|
if event.type == pygame.QUIT:
|
|
run = False
|
|
|
|
pygame.time.delay(200)
|
|
if game.finalState():
|
|
break
|
|
if len(game.getPath()) == 0:
|
|
path = game.findBomb()
|
|
game.savePath(path)
|
|
game.moveToNext()
|
|
game.update()
|
|
|
|
|
|
main()
|