Check out Grant Acedrex, our featured variant for April, 2024.


[ Help | Earliest Comments | Latest Comments ]
[ List All Subjects of Discussion | Create New Subject of Discussion ]
[ List Earliest Comments Only For Pages | Games | Rated Pages | Rated Games | Subjects of Discussion ]

Single Comment

Game Courier Developer's Guide. Learn how to design and program Chess variants for Game Courier.[All Comments] [Add Comment or Rating]
🕸📝Fergus Duniho wrote on Tue, Aug 25, 2020 01:45 AM UTC in reply to Fergus Duniho from Mon Aug 24 09:54 PM:

Since this would not work properly with moving pieces by clicking on the destination first, I removed that capability. It will now only show where the piece clicked on can move to. It will no longer show which pieces can move to a particular space.

I have restored that ability, and I enhanced the ability to quickly make moves. I renamed the old showLegal() function to showAllLegal(), and I renamed the new one to showNextLegal(). As these names suggest, showNextLegal does not always show as many legal moves as showAllLegal() does. Since showNextLegal() applies clicks in order, it may exclude moves that showAllLegal(), which does not apply clicks in order, would not exclude. Because showAllLegal() returns all possible moves involving a space, it can be used to determine if there is only one legal move involving that space. This allows Game Courier to play a move right away when it determines that there is only one legal move involving the space clicked on. This now works for enemy pieces as well as empty space. But it will not work when you click on one of your own pieces to see its legal moves. In that case, it will display the legal moves even if there is only one, and it will not play the move automatically.