Moved initialisation from BaseGame to GameUtils
This commit is contained in:
17
src/base.py
17
src/base.py
@ -1,6 +1,19 @@
|
|||||||
class Game:
|
class Game:
|
||||||
def __init__(self):
|
def __init__(self, surface, playerManager):
|
||||||
pass
|
"""
|
||||||
|
Initialises some things for the game developers.
|
||||||
|
|
||||||
|
Args:
|
||||||
|
surface (pygame.Surface): The surface the game devs draw on.
|
||||||
|
platerManager (NoPELib.PlayerManager): The player manager.
|
||||||
|
"""
|
||||||
|
|
||||||
|
self.surf = surface
|
||||||
|
self.size = self.surface.size
|
||||||
|
self.pm = playerManager
|
||||||
|
|
||||||
|
with open('./game.toml', 'r') as f:
|
||||||
|
self.cfg = tomllib.loads(f.read())
|
||||||
|
|
||||||
def update(self):
|
def update(self):
|
||||||
pass
|
pass
|
||||||
|
|||||||
Reference in New Issue
Block a user