LabinatorSolutions / stockfish-chess-web-gui

Responsive chess web GUI to play against the Stockfish 16 chess engine. Multiple web GUI implementations have also been included.
https://labinatorsolutions.github.io/stockfish-chess-web-gui/
GNU Affero General Public License v3.0
58 stars 40 forks source link

Resolving issues with historical and AI to Player #28

Closed rockcesar closed 5 months ago

rockcesar commented 3 years ago

Deleting the functionality of load the board when click on historical. Only commenting the lines. Issue: https://github.com/LabinatorSolutions/stockfish-chess-web-gui/issues/23

Deleting the functionality of toggle from AI to Player. Only commenting the lines. Issue: https://github.com/LabinatorSolutions/stockfish-chess-web-gui/issues/24

LabinatorSolutions commented 3 years ago

It would be ideal if we can resolve the issue instead of deleting the functionality. We can not delete the functionality without checking first if there are ways to keep the features while addressing the bug.

rockcesar commented 3 years ago

Both functionalities are working in Desktop, but Mobile view isn't working completed.

By now, that's my solution: https://github.com/LabinatorSolutions/stockfish-chess-web-gui/issues/23

rockcesar commented 3 years ago

With this pull request, I disable both functionalities for Mobile and Desktop. To enable it, we should redefine these libs called in index.html, for mobile:

    `if (isMobile == true) {

        var chess, board;

        loadCss('chessboard-css', 'css/caustique-chessboard.css');

        $.getScript('js/chessboard-caustique-min.js', initGameBoard('mobile'));
        $.getScript('js/board-controls-side.js', initGameBoard('mobile'));
        $.getScript('js/board-controls-bottom.js', initGameBoard('mobile'));
        $.getScript('js/board-sets.js', initGameBoard('mobile'));

        $.getScript('js/board-time.js', initGameBoard('mobile'));
        $.getScript('js/board-actions.js', initGameBoard('mobile'));
        $.getScript('js/board-actions-mobile.js', initGameBoard('mobile'));
        $.getScript('js/board-init.js', initGameBoard('mobile'));

    } else {

        loadCss('chessboard-css', 'css/chessboard.css');

        $.getScript('js/chessboard.min.js', initGameBoard('desktop'));
        $.getScript('js/board-controls-side.js', initGameBoard('desktop'));
        $.getScript('js/board-controls-bottom.js', initGameBoard('desktop'));
        $.getScript('js/board-sets.js', initGameBoard('desktop'));

        $.getScript('js/board-time.js', initGameBoard('desktop'));
        $.getScript('js/board-actions.js', initGameBoard('desktop'));
        $.getScript('js/board-actions-desktop.js', initGameBoard('desktop'));
        $.getScript('js/board-init.js', initGameBoard('desktop'));

    }`
rockcesar commented 3 years ago

I guess the problem is directly this js/board-actions-mobile.js, but it requires more effort for development, because it's redefine almost all mobile actions, that is not completed.

rockcesar commented 3 years ago

My two options are do the effort to redefine Mobile or disable those options for playing, by now. Inmediately, I can help disabling it. But I understand it should be working.

LabinatorSolutions commented 3 years ago

Thank you for explaining the bug and suggesting possible solutions. We will keep this issue open until we get time to review this issue more thoroughly. At this point in time, we won't merge it with the main branch since we need to evaluate some possible solutions before removing the feature. All in all, thank you for your contribution.