update gitignore and consts to use path var from config.py

This commit is contained in:
matixezor 2021-03-11 16:20:40 +01:00
parent 1ef4ec94a2
commit d7b1899dc4
2 changed files with 7 additions and 4 deletions

1
.gitignore vendored
View File

@ -5,6 +5,7 @@
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
src/config.py
.idea
# User-specific stuff
.idea/**/workspace.xml

View File

@ -1,14 +1,16 @@
from pygame import image
from config import main_path
WIDTH = 800
HEIGHT = 800
IMAGES = []
for img in ['grass_01', 'grass_02', 'grass_mine_01', 'grass_mine_02', 'grass_rock_01', 'grass_rock_02']:
IMAGES.append(image.load('C:/Users/matix/Documents/Python/Saper/images/Tiles/' + img + ".png"))
IMAGES.append(image.load(main_path + 'images/Tiles/' + img + ".png"))
ICON = 'C:/Users/matix/Documents/Python/Saper/images/mine_icon.png'
SAPPER_IDLE = image.load('C:/Users/matix/Documents/Python/Saper/images/sapper_idle/cpt_bomba.png')
ICON = main_path + 'images/mine_icon.png'
SAPPER_IDLE = image.load(main_path + 'images/sapper_idle/cpt_bomba.png')
SAPPER_RUNNING = []
"""for img in [
@ -25,7 +27,7 @@ for img in [
'cpt_bomba_left',
'cpt_bomba_right',
]:
SAPPER_RUNNING.append(image.load('C:/Users/matix/Documents/Python/Saper/images/sapper_idle/' + img + ".png"))
SAPPER_RUNNING.append(image.load(main_path + 'images/sapper_idle/' + img + ".png"))
DEFAULT_FIELD = [
[1, 3, 4, 5, 0, 1, 2, 3, 2, 0],