The Chess Variant Pages




[ 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 ]

Comments/Ratings for a Single Item

Earlier Reverse Order Later
Grand Apothecary Chess-Alert. Very large Board variant obtained trough tinkering with known games.[All Comments] [Add Comment or Rating]
Aurelian Florea wrote on 2021-04-24 UTC

This article is ready for review!


Aurelian Florea wrote on 2021-04-25 UTC

Actually while testing with the interactive diagram I have noticed some undesired results. So I'm modifying a bit the game. Please allow me some more time.


Aurelian Florea wrote on 2021-05-06 UTC

To the editors. Now this article is ready for review.


Aurelian Florea wrote on 2021-05-18 UTC

May an editor look over this article?


Aurelian Florea wrote on 2021-08-23 UTC

@ HG&Fergus

I have changed the piece names in the automatically generated preset here: https://www.chessvariants.com/play/pbm/play.php?game=Grand+Apothecary+Chess+1&settings=Applet

The mortar seems to be able to capture from the initial position on the home brouhaha squares. Any thoughts on that?


Fergus Duniho wrote on 2021-08-23 UTC

I am not familiar with how these automatically generated presets work. It looks like it might be trying to emulate logical directions without using the built-in support for logical directions. I cannot tell what piece the Mortar is or how it moves from this code.


H. G. Muller wrote on 2021-08-24 UTC

I think the problem is that you use piece IDs that are not purely alphabetic, like .ZW or 1BI. The GAME code in the betza.txt include file recognizes the color of the pieces through the operaters islower and isupper for determining whether a piece is black or white. This doesn't work properly on digits or punctuation. So it allows the Mortar in the initial position to capture to the brouhaha square because it does not consider the piece there to be a white one (and thus considers it fair game for capture).

Perhaps Fergus can tell if there are alternatives to islower and isupper that ignore non-alphabetic characters, (or judge only the first letter in the string), and thus can be used to reliably recognize color in an environment of names that contain digits / punctuation. My first thought would of course be to outlaw such piece names in the fist place: it seems totally silly to allow such names. There doesn't seem any need for it.


Fergus Duniho wrote on 2021-08-24 UTC

Perhaps Fergus can tell if there are alternatives to islower and isupper that ignore non-alphabetic characters, (or judge only the first letter in the string), and thus can be used to reliably recognize color in an environment of names that contain digits / punctuation. My first thought would of course be to outlaw such piece names in the fist place: it seems totally silly to allow such names. There doesn't seem any need for it.

My recommendation is to change the piece labels, which I have previously documented how to do. This would require extra programming, though, which could defeat the purpose of having all the code generated for you. Perhaps code for changing piece labels could be automatically generated with the other code. This would require you to enter both the original piece label and the notation you want to use for the piece. See recent comments to the Developer's Guide for details on what kind of code is needed to do this.


H. G. Muller wrote on 2021-08-24 UTC

I will check this out, to see if it is something that should be done in the automatically generated code, or whether this would be something that is better done by the end user in addition to the generated code.

I still want to explore an alternative solution, though: would it be possible to have GAME code support operators nolower and noupper, as analogs to isupper and islower? E.g. nolower would return true if its string argument would not contain any lower case characters, i.e. if it is all upper case, digits or punctuation. The operators isupper and islower turn out not to be very useful in an environment where piece labels can contain digits and punctuation.


Fergus Duniho wrote on 2021-08-24 UTC

would it be possible to have GAME code support operators nolower and noupper, as analogs to isupper and islower?

No, those are already in use for returning arrays of spaces. Also, PHP doesn't have a ctype function for what you want.

E.g. nolower would return true if its string argument would not contain any lower case characters, i.e. if it is all upper case, digits or punctuation.

With #0 standing in for the space with the piece in question, try using match #0 nolower. This will check whether it's among the spaces whose pieces have no lowercase letters in them. Or with #0 as the piece label, you could try not fnmatch "*[a-z]*" space #0. This checks it against a wildcard pattern for containing any lowercase ASCII characters, then negates the result.


Fergus Duniho wrote on 2021-08-24 UTC

I just updated explode to work with an empty separator, and I wrote and tested this function:

def nolowercase allfalse lambda (islower #0) explode "" #0;

H. G. Muller wrote on 2021-08-25 UTC

OK, I replaced the islower everywhere in the include file by fnmatch "*[a-z]*", and isupper by fnmatch "*[A-Z]*". This seems to solve the problem of friend/foe discrimination. I hope there aren't any piece sets that use piece labels that mix upper and lower case...


Aurelian Florea wrote on 2022-02-12 UTC

I have added in this game's initial position one regular pawn on each flank on the fourth row. That is because flank attacks by white where too dangerous in start positions where the black rook of the file was undefended. Also more king safety should he castle.


Aurelian Florea wrote on 2022-02-22 UTC

I have added in the notes sections explanations about why are the pieces are the way they are in this game. They are not perfect, but I had questions and I wanted to answer them.


14 comments displayed

Earlier Reverse Order Later

Permalink to the exact comments currently displayed.