]> git.cworth.org Git - lmno.games/commitdiff
tictactoe: Don't let the user send an illegal move
authorCarl Worth <cworth@cworth.org>
Thu, 4 Jun 2020 00:37:59 +0000 (17:37 -0700)
committerCarl Worth <cworth@cworth.org>
Thu, 4 Jun 2020 00:37:59 +0000 (17:37 -0700)
The client already knows which squares are occupied, and when the game
is won, so it's pointless to ever send a move we know is going to be
rejected. And in fact, we shouldn't even give the user a hover
indication as if they could move there.

That's all implemented in this commit. The hover highlight and the
pointer cursor are both disabled for squares that are already
occupied, and for all squares once the game is over.


No differences found