created a package for objects, changed ui into a package
This commit is contained in:
parent
b6fa5844fa
commit
7ef7c24339
@ -3,9 +3,9 @@ import pygame
|
||||
import project_constants as const
|
||||
from assets import asset_constants as asset
|
||||
|
||||
from mine_models.standard_mine import StandardMine
|
||||
from mine_models.chained_mine import ChainedMine
|
||||
from mine_models.time_mine import TimeMine
|
||||
from objects.mines.standard_mine import StandardMine
|
||||
from objects.mines.chained_mine import ChainedMine
|
||||
from objects.mines.time_mine import TimeMine
|
||||
|
||||
|
||||
# ================================= #
|
||||
|
4
game.py
4
game.py
@ -7,7 +7,7 @@ from searching_algorithms import a_star
|
||||
|
||||
from minefield import Minefield
|
||||
|
||||
from mine_models.time_mine import TimeMine
|
||||
from objects.mines.time_mine import TimeMine
|
||||
|
||||
from ui.ui_components_manager import UiComponentsManager
|
||||
from ui.text_box import TextBox
|
||||
@ -187,7 +187,7 @@ class Game:
|
||||
self.minefield = self.initial_minefield.__copy__()
|
||||
self.agent = self.initial_minefield.agent
|
||||
|
||||
# initializes ui components and assigns them to attributes
|
||||
# initializes old ui components and assigns them to attributes
|
||||
def initialize_gui_components(self):
|
||||
# calculating in game gui coordinates
|
||||
gui_width = const.V_SIDE_MENU_WIDTH
|
||||
|
@ -4,12 +4,12 @@ import random
|
||||
import project_constants as const
|
||||
|
||||
# import tile class
|
||||
from tile import Tile
|
||||
from objects.tile import Tile
|
||||
|
||||
# import mine models
|
||||
from mine_models.standard_mine import StandardMine
|
||||
from mine_models.time_mine import TimeMine
|
||||
from mine_models.chained_mine import ChainedMine
|
||||
from objects.mines.standard_mine import StandardMine
|
||||
from objects.mines.time_mine import TimeMine
|
||||
from objects.mines.chained_mine import ChainedMine
|
||||
|
||||
|
||||
class JsonGenerator:
|
||||
|
@ -1,7 +1,6 @@
|
||||
import agent as ag
|
||||
import project_constants as const
|
||||
import tile as tl
|
||||
from mine_models.time_mine import TimeMine
|
||||
from objects import tile as tl, agent as ag
|
||||
from objects.mines.time_mine import TimeMine
|
||||
import json_generator as jg
|
||||
|
||||
|
||||
|
0
objects/__init__.py
Normal file
0
objects/__init__.py
Normal file
0
objects/mines/__init__.py
Normal file
0
objects/mines/__init__.py
Normal file
@ -150,7 +150,7 @@ def get_tile_coordinates(position):
|
||||
# initializing pygame modules so all instances can be constructed properly
|
||||
pygame.init()
|
||||
|
||||
# creating ui components used in menu
|
||||
# creating old ui components used in menu
|
||||
HIGHLIGHT = pygame.transform.scale(
|
||||
pygame.image.load(os.path.join(DIR_ASSETS, "old_tiles/tile_white.png")),
|
||||
(V_TILE_SIZE, V_TILE_SIZE)
|
||||
|
0
ui/__init__.py
Normal file
0
ui/__init__.py
Normal file
Loading…
Reference in New Issue
Block a user