cleaner children/undo view and show regardless of eval
This commit is contained in:
1 parent
eba8cddda1
commit
b8cfbddd15
2 files changed
+6
-6
No files matched your search
+2
-2
@@ -17,8 +17,8 @@
|
|||||||
"stones": [ [0.05, 0.05, 0.05], [0.95, 0.95, 0.95] ],
|
"stones": [ [0.05, 0.05, 0.05], [0.95, 0.95, 0.95] ],
|
||||||
"ghost_alpha": 0.5,
|
"ghost_alpha": 0.5,
|
||||||
"eval_colors": [[0.537, 0.129, 0.42], [1, 0, 0], [1, 0.95, 0], [0.117, 0.588, 0]],
|
"eval_colors": [[0.537, 0.129, 0.42], [1, 0, 0], [1, 0.95, 0], [0.117, 0.588, 0]],
|
||||||
"undo_circle_col": [0.88,0.02,0.17,0.5],
|
"undo_alpha": 0.5,
|
||||||
"undo_alpha": 0.5,
|
"undo_scale": 0.95,
|
||||||
"eval_knots": [0, 0.5, 0.875, 1],
|
"eval_knots": [0, 0.5, 0.875, 1],
|
||||||
"eval_bounds": [1,12],
|
"eval_bounds": [1,12],
|
||||||
"board_margin": 1.5,
|
"board_margin": 1.5,
|
||||||
|
|||||||
+4
-4
@@ -148,15 +148,15 @@ class BadukPanWidget(Widget):
|
|||||||
Rectangle(pos=(self.gridpos[x] - rsz / 2, self.gridpos[y] - rsz / 2), size=(rsz, rsz))
|
Rectangle(pos=(self.gridpos[x] - rsz / 2, self.gridpos[y] - rsz / 2), size=(rsz, rsz))
|
||||||
ix = ix + 1
|
ix = ix + 1
|
||||||
|
|
||||||
# undos
|
# children of current moves in undo / review
|
||||||
undo_coords = set()
|
undo_coords = set()
|
||||||
alpha = Config.get("ui")["undo_alpha"]
|
alpha = Config.get("ui")["undo_alpha"]
|
||||||
for m in last_move.children:
|
for m in last_move.children:
|
||||||
eval_info = m.evaluation_info
|
eval_info = m.evaluation_info
|
||||||
if eval_info[0] and m.coords[0] is not None:
|
if m.coords[0] is not None:
|
||||||
undo_coords.add(m.coords)
|
undo_coords.add(m.coords)
|
||||||
evalcol = (*self._eval_spectrum(eval_info[0]), alpha)
|
evalcol = (*self._eval_spectrum(eval_info[0]), alpha) if eval_info[0] else None
|
||||||
self.draw_stone(m.coords[0], m.coords[1], (*COLORS[m.player][:3], alpha), Config.get("ui")["undo_circle_col"], evalcol, self.EVAL_BOUNDS[1])
|
self.draw_stone(m.coords[0], m.coords[1], (*COLORS[m.player][:3], alpha), None, evalcol, self.EVAL_BOUNDS[1], scale=Config.get("ui").get("undo_scale", 0.95))
|
||||||
|
|
||||||
# hints
|
# hints
|
||||||
if self.engine.hints.active(current_player):
|
if self.engine.hints.active(current_player):
|
||||||
|
|||||||
Reference in new issue
Block a user