Михаил Капелько 4 miesięcy temu
rodzic
commit
60dbfb4ae6
3 zmienionych plików z 7 dodań i 4 usunięć
  1. +4
    -4
      v5/gui.py
  2. +2
    -0
      v5/main-gui.py
  3. +1
    -0
      v5/memory_Context.py

+ 4
- 4
v5/gui.py Wyświetl plik

@@ -47,12 +47,14 @@ def gui_generateTilePositions(
) -> memory_Context:
if (
(
c.recentField != "cellPositions" and
c.recentField != "cellSize" and
c.recentField != "playfieldSize" and
c.recentField != "windowHeight" and
c.recentField != "windowWidth"
) or
(
len(c.cellPositions) == 0 or
c.cellSize == 0 or
c.playfieldSize == 0 or
c.windowHeight == 0 or
@@ -63,11 +65,9 @@ def gui_generateTilePositions(
return c
#}

positions = gui_aux_cellPositions(c.playfieldSize)

ps = []
for i in range(0, len(positions)):
p = gui_aux_cellScreenPosition(c, positions[i])
for i in range(0, len(c.cellPositions)):
p = gui_aux_cellScreenPosition(c, c.cellPositions[i])
ps.append(p)
#}



+ 2
- 0
v5/main-gui.py Wyświetl plik

@@ -8,6 +8,7 @@ from desktop_Platform import *
from desktop_SequentialTimer import *
from desktop_Window import *
from gui import *
from gui_aux import *
from gui_aux_test import *
from gui_test import *
from llm_test import *
@@ -101,6 +102,7 @@ ctrl.registerCallback(process)
ctrl.set("didLaunch", True)
ctrl.set("playfieldSize", 2)

ctrl.set("cellPositions", gui_aux_cellPositions(2))
ctrl.set("cellSize", 25)
ctrl.set("deselectMismatchedTilesDelay", 500)
ctrl.set("hideMatchingTilesDelay", 500)


+ 1
- 0
v5/memory_Context.py Wyświetl plik

@@ -1,5 +1,6 @@
class memory_Context:
def __init__(self):
self.cellPositions = []
self.cellSize = 0
self.deselectMismatchedTiles = False
self.deselectMismatchedTilesDelay = 0


Ładowanie…
Anuluj
Zapisz