-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathRPGgame.py
37 lines (28 loc) · 840 Bytes
/
RPGgame.py
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
35
36
37
# -*- coding: utf-8 -*-
"""
Created on Thu May 11 20:05:57 2023
@author: alexa
"""
import pygame, sys
from settings import *
from level import Level
from debug import debug
class Game:
def __init__(self):
self.screen = pygame.display.set_mode((WIDTH,HEIGHT))
pygame.display.set_caption('Celcius')
self.clock = pygame.time.Clock()
self.level = Level()
def run(self):
while True:
for event in pygame.event.get():
if event.type == pygame.QUIT:
pygame.quit()
sys.exit()
self.screen.fill('black')
self.level.run()
pygame.display.update()
self.clock.tick(FPS)
if __name__ == '__main__':
game = Game()
game.run()