1
$\begingroup$

I want to make a chessboard with pieces and move those pieces with drag and drop using the mouse, is that possible?

$\endgroup$
1
  • 1
    $\begingroup$ I am waiting for the question "How to turn off my TV with Mathematica?" $\endgroup$
    – user64494
    Apr 3 at 14:00

1 Answer 1

4
$\begingroup$

It's the winner of 2021 one-liner competition, isn't it?

Graphics@{Raster@Array[.9^+## &, {8, 8}], 
  MapIndexed[
    Locator[#2 - .5, #] &, {b = {\[WhiteRook], \[WhiteKnight], \[WhiteBishop], \
\[WhiteQueen], \[WhiteKing], \[WhiteBishop], \[WhiteKnight], \[WhiteRook]}, 
     y = Table[\[WhitePawn], 8], 3, , , , y, b}, {2}] /. 3 -> Red}
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.