dkforest

A forum and chat platform (onion)
git clone https://git.dasho.dev/n0tr1v/dkforest.git
Log | Files | Refs | LICENSE

commit e6e7d7a2cc48807832e25c1780c569c17af314c6
parent 1fb92b09915718f3c50a2c06829e26d360ab4559
Author: n0tr1v <n0tr1v@protonmail.com>
Date:   Fri, 16 Jun 2023 19:51:52 -0700

bad way of showing the last move in graph

Diffstat:
Mpkg/web/handlers/interceptors/chess.go | 4++++
1 file changed, 4 insertions(+), 0 deletions(-)

diff --git a/pkg/web/handlers/interceptors/chess.go b/pkg/web/handlers/interceptors/chess.go @@ -963,6 +963,10 @@ func AnalyseGame(pgn string, t int64) (out AnalyseResult, err error) { // scores = append(scores, Score{Move: moveStr, BestMove: "", CP: cp, Mate: mate}) //} logrus.Error(err) + mov := g.MoveHistory()[idx-1].Move + moveStr := chess.AlgebraicNotation{}.Encode(positions[idx-1], mov) + cps = append(cps, 0) + scores = append(scores, Score{Move: moveStr}) continue } res := eng.SearchResults()