The Chess Variant Pages
Custom Search

[ 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

This item is a reference work
It belongs to categories: Orthodox chess, 
It was last modified on: 2015-11-06
 By H. G.  Muller. Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
Adam DeWitt wrote on 2020-04-26 UTC

About your idea of including piece descriptions in the piece table:

Overall, including piece descriptions in the piece table is a good idea that I think should be implemented. Here are my thoughts on it:

First and foremost, including piece descriptions for a piece in this way should be optional, so you don't have to do it for every single piece in the table, which would be quite tedious, especially for larger games like Hook Shogi and Taishin Shogi. Of course, you can put in default descriptions for predefined pieces, but the programmer should also have the ability to override these. For null descriptions you could simply replace the empty string with a hyphen.

Regarding implementation, I recommend putting all the piece descriptions in an array so you can use JavaScript variables to hold piece descriptions if need be. And when setting piece descriptions in the diagram script, I would suggest putting the descriptions after everything else in the colon-separated list, like so:


This way already existing diagrams won't get screwed up by this new implementation.

If you do implement this, make sure to update this page to include information about it.