🕸📝Fergus Duniho wrote on Tue, Aug 25, 2020 03:34 AM UTC:
I was interrupted when I was writing before, and I just now remembered something I wanted to include. By using showNextLegal(), the code can tell that a piece has no legal moves of its own, and by using showAllLegal(), it can then tell how many legal moves there are to that space. It is through using both together that one-click moving to a space occupied by an enemy piece is made possible.
I was interrupted when I was writing before, and I just now remembered something I wanted to include. By using showNextLegal(), the code can tell that a piece has no legal moves of its own, and by using showAllLegal(), it can then tell how many legal moves there are to that space. It is through using both together that one-click moving to a space occupied by an enemy piece is made possible.