summaryrefslogtreecommitdiff
path: root/src/sliceitoff/game
diff options
context:
space:
mode:
authorViljami Ilola <+@hix.fi>2024-04-21 00:03:22 +0300
committerViljami Ilola <+@hix.fi>2024-04-21 00:03:22 +0300
commit9f808fa0e43ae903d6159848d1331dcccb91434d (patch)
tree4e45858383aff0399184395875966765bb9964cb /src/sliceitoff/game
parent360a680cdb03df60673581a8f187c4074a78dd21 (diff)
fonts as object
Diffstat (limited to 'src/sliceitoff/game')
-rw-r--r--src/sliceitoff/game/game.py8
-rw-r--r--src/sliceitoff/game/gameplay.py2
-rw-r--r--src/sliceitoff/game/mainmenu.py2
-rw-r--r--src/sliceitoff/game/show.py2
4 files changed, 7 insertions, 7 deletions
diff --git a/src/sliceitoff/game/game.py b/src/sliceitoff/game/game.py
index 7a91ede..a5009c5 100644
--- a/src/sliceitoff/game/game.py
+++ b/src/sliceitoff/game/game.py
@@ -1,5 +1,5 @@
-""" Slice It Off! - Game where you slice the area where enemies reside to
- the minimum
+""" game.game - Slice It Off! - Game where you slice the area where smily
+ faces reside to the minimum.
"""
from pathlib import Path
@@ -7,13 +7,13 @@ from pathlib import Path
import pygame
from sliceitoff.display import Display
-from sliceitoff.text import Fonts
from sliceitoff.stats import Stats
from sliceitoff.screens import (
hiscores_screen,
instructions1_screen,
instructions2_screen)
from sliceitoff.hiscores import HiScores
+from sliceitoff.text import fonts
from sliceitoff.sfx import sfx
from .mainmenu import Mainmenu, MenuItems
@@ -27,11 +27,11 @@ class Game:
assets_path = Path(__file__).parent.parent.resolve().joinpath('assets')
pygame.init()
sfx.init(assets_path)
+ fonts.init(assets_path)
self.clock = pygame.time.Clock()
self.display = Display()
self.stats = None
self.hiscores = HiScores()
- Fonts.load_fonts(assets_path)
pygame.mouse.set_visible(False)
def __del__(self):
diff --git a/src/sliceitoff/game/gameplay.py b/src/sliceitoff/game/gameplay.py
index c756183..fe66f50 100644
--- a/src/sliceitoff/game/gameplay.py
+++ b/src/sliceitoff/game/gameplay.py
@@ -1,4 +1,4 @@
-""" Reads user input and does actions when game play is on. """
+""" game.gameplay - Reads user input and does actions when game play is on."""
import pygame
from sliceitoff.sfx import sfx
diff --git a/src/sliceitoff/game/mainmenu.py b/src/sliceitoff/game/mainmenu.py
index b4287d7..edb1594 100644
--- a/src/sliceitoff/game/mainmenu.py
+++ b/src/sliceitoff/game/mainmenu.py
@@ -1,4 +1,4 @@
-""" mainmenu.mainmenu - Let's user choose """
+""" game.mainmenu - Let's user choose """
from enum import IntEnum
import pygame
diff --git a/src/sliceitoff/game/show.py b/src/sliceitoff/game/show.py
index 496fc4a..32a87cf 100644
--- a/src/sliceitoff/game/show.py
+++ b/src/sliceitoff/game/show.py
@@ -1,4 +1,4 @@
-""" Sprite group that show sprites and skips if key is pressed """
+""" game.show - Sprite group that show sprites and skips if key is pressed """
from .anykey import anykey
from .explodeout import ExplodeOutGroup