Fix: neue Züge wurden nicht angezeigt (Brett/Zugliste blieben in Startposition)
This commit is contained in:
@@ -48,6 +48,13 @@ async function loadPGN(showOverlay = true) {
|
||||
const liveGame = getLiveGame(allLaraGames);
|
||||
const todaysGames = getTodaysGames(allLaraGames);
|
||||
currentGame = liveGame || (todaysGames.length > 0 ? getLatestGame(todaysGames) : getLatestGame(allLaraGames));
|
||||
} else if (currentGame) {
|
||||
const updatedGame = allLaraGames.find(g =>
|
||||
g.white === currentGame.white &&
|
||||
g.black === currentGame.black &&
|
||||
g.round === currentGame.round
|
||||
);
|
||||
if (updatedGame) currentGame = updatedGame;
|
||||
}
|
||||
updateBoard();
|
||||
updatePlayerInfo();
|
||||
|
||||
Reference in New Issue
Block a user