Would someone be interested in programming....

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

Alessandro Scotti

Re: Would someone be interested in programming....

Post by Alessandro Scotti »

hgm wrote:I guess if I would play white with Camels and black with Knights, I could simply set the white Knight of a fairy character (say an upside-down Knight), and leave the black Knight a standard Knight. I only run into trouble if white has both a Knight and a Camel.
Yes that's correct.
hgm wrote:Another problem is that alternating the Camels between black and white would not work anymore. The black Knights would continue to be displayed as ordinary black Knights in the games where black had the Camels, so that I still would not be able to see which side has the Camels without watching the game until one of them moves a Knight or Camel.
I think you can restart Winboard with a different settings for the font mapping, will waste some time but it should work.
hgm wrote:Would it be easy to expand the number of piece types in Winboard? (i.e. is this just the matter of changing a defined constant from 6 to, say, 9, or is the 6 hard-coded in many places in Winboard?)
Well in theory it should be possible because Winboard has been designed to support variants as well as standard chess, but I have no idea how easy it is.
hgm wrote:I tried playing with the /fontPieceToCharTable option without giving a font, but then it is simply ignored. Where do the standard Winboard pieces come from? Are those stored as initialized data in the program, or are they read from bitmap files?
Yes that option only works when you use font based pieces, otherwise Winboard uses bitmaps (and lots of them as they have been rendered for many different board sizes). Bitmaps files are stored in a subdirectory IIRC. Edit: it's possible I confuse the source tree with the compiled stuff... if you can find no bitmaps around then they have been included into the executable as resources.
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Would someone be interested in programming....

Post by hgm »

I guess the bitmaps are included in the .exe, as it is 1.9MB, which seems bit large for just a bit of code. I couldn't find a folder.

I guess I should forget about the idea of watching the games, unless there really exists a fairy GUI that can do matches. After all, the important thing is to get a statistically significant result, not to provide video-amusement. :lol:
neoliminal

Re: Would someone be interested in programming....

Post by neoliminal »

I guess I should forget about the idea of watching the games, unless there really exists a fairy GUI that can do matches. After all, the important thing is to get a statistically significant result, not to provide video-amusement. Laughing
I don't know. I really learned a lot watching Core Wars from display. Particularly being able to mark certain parts and then play that game back to see exactly what happened and why.

But I like watching things like that.
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Would someone be interested in programming....

Post by hgm »

Sure, it would be nice if it could be done. But if the amount of effort involved is hug, it is simply not worth it.
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Would someone be interested in programming....

Post by hgm »

neoliminal wrote:I also make piece sets. Should you figure out a way to include fairy pieces, I'd be happy to make whatever you need. Examples of my work can bee seen here:

http://wiki.schemingmind.com/SmWiki/PieceSets

(may require free registration)
Well, the option of having Winboard map the regular pieces to any character of a user-selectable font, for each color separately, is definitely a useful option if one side does not have more than 6 different piece types. I will try to see if I can modify Winboard to actually use 9 different piece types internally, so that the initial setup always has 8 different piece types on the back rank, and in the default setting simply use the same symbols for, (and same move-generator case for move-legality checking), say, queen-side rook and king-side rook.

I strongly dislike the standard representation of fairy pieces, as rotated FIDE pieces, though. In addition I am not too charmed by the "Good Companion", let alone "Berliner" Chess fonts that support those. (Turns out I dislike skinny Pawns...)

So if it is not a very big job, I would like you to design a font that allow a more natural and intuitive representation of the fairy pieces. The standard Chess symbols seem to be designed according to the following guidelines:
* Animals are represented by their head (e.g. Horse figure for a Knight)
* Inanimate equipment is simply drawn (e.g. Castle for a Rook)
* Human characters are symbolized by their head covers

We could add a class of abstract geometric figures, as I designed for representing Ultima / Baroque pieces:

Image

Working along those guidelines, Camel, Elephant, Giraffe, Bison, Gnu, Grasshopper would become reasonably realistic pictograms of their heads from the neck up. Stuff like Dabbabah (catapult) and Canon would be silhouettes of the entire object. The most tricky part is to find representations for the Human pieces. The royal vs non-royal distincion is an issue here. A Commoner (aka Man) moves as a King, but obviously representing it as a King causes confusion, and representing it by some kind of downgraded crown makes no sense, as it is non-royal. I like the idea of using a German Helmet here, as the silhouette roughly reminds of the royal crown (with a spike on top in stead of a cross), while it conveys the idea that the piece is basically canon fodder. The classical pieces Ferz (=General) and Wazir (=Grand Vizor) could be represented by a U.S. Civil-War-style hat with general markings, and a turban, respectively. Although for the General, a Chinese Mandarin hat might actually be a better alternative. (The Xianggi Mandarins, are basically Ferzes, confined to the Palace section of the board). Other characteristic head covers are a tropical helmet (Canvasser = Camel + Rook), a larger turban-like crown (Caliph = Camel + Bishop), a pointy hat (Wizzard?) or a Greek Phalanx helmet (Champion?), a chef's hat (is there any fairy piece called a Cook???).

Many composite pieces combine the gait of a Knight with that of other existing pieces. This is so common, that it seems useful to develop a general mechanism for indicating such 'mounted' pieces. I would suggest depicting a horse shoe and stirrups below a (slightly de-magnified) version of the basic piece. E.g. an Amazon would be a mounted Queen, The ArchBishop a mounted Bishop, the Centaur a mounted Commoner (it can be debated if the Centaur is an animal, but the 'from-the-neck-up' guideline makes it unsuitable for representation as one). The Marshal would be symbolized by a hat, as having a mounted Rook seems to make little sense.
The Zebra can be a usual Knight symbol with black and white stripes on the neck (the color of the head revealing the side it is on). The NightRider could be a Knight with 'air-flow stripes' (or waving mane) trailing behind it. (This could be adopted as a general mechanism to indicate riders, although I am not sure there are many others.) The Xianggi Horse could be simply a Knight looking the other way.

Some sketches I made:

Image

Basically I wanted to conform as much as possible to the normal Winboard piece symbols, but I noticed too late that the head covers there actually have rounded bottoms, so for unity of style it would probably be better to change the perspective of the helmets a little.

Image

For the mapping of the alphabet to the symbols, it would be most easy to have upper case designate white pieces, and lower case the corresponding black pieces (I do not need pieces with background white or black squares, Winboard takes care of that). Preferentially with an easy-to-remember mapping, that could also be used in FENs. E.g.

A = ArchBishop
B = Bishop
C = Camel
D = Dabbabah
E = Elephant
F = Ferz
G = Grasshopper (depicted as Praying Mantiss)
H = NightRider
I = Square (Ultima Immobilizer)
K = King
L = Caliph
M = Commoner / Man
N = Knight
O = Sphere (Ultima Chameleon)
P = Pawn
Q = Queen
R = Rook
S = Marshal / Chancellor
T = Draughts Chip
U = Unicorn
V = Bullet (Ultima Withdrawer)
W = Wazir
X = Disk antenna (Ultima Coordinator)
Y = Cylinder (Ultima Long Leaper)
Z = Zebra

Most notably missing are Amazon and Xianggi Canon.
neoliminal

Re: Would someone be interested in programming....

Post by neoliminal »

Is that board you are showing me there the right size?

does it use .gif with transparent backgrounds or .png?
Alessandro Scotti

Re: Would someone be interested in programming....

Post by Alessandro Scotti »

Hi H.G.,
nice designs! :-)
My only comment is that it probably better to have pieces that are a "whole part" and not made of disjoint shapes.
User avatar
Ovyron
Posts: 4556
Joined: Tue Jul 03, 2007 4:30 am

Re: Would someone be interested in programming....

Post by Ovyron »

Here are some fairy pieces as represented by websites or playing programs:

SMIRF:

Archbishop
Image

Chancellor
Image

Chessville:

Archbishop
Image

Chancellor
Image

Chessvariants / Applet:

Archbishop:
Image Image Image

Camel:
Image Image

Dabbaba:
Image
Image

Elephant:
Image Image Image

Ferz:
Image Image Image Image Image Image

Grasshopper:
Image

NightRider:
Image

Caliph:
Image

Commoner:
Image Image Image

Chancellor:
Image Image Image

Withdrawer:
Image

Wazir:
Image

Zebra:
Image

Amazon:
Image Image Image

Cannon:
Image

Just for... design inspiration... :)
Your beliefs create your reality, so be careful what you wish for.
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Would someone be interested in programming....

Post by hgm »

I definitely like the middle Elephant here better than mine. By showing more "body" on the lower-right it approaches the style of the original Winboard symbols more closely. The winboard Knight is looking a bit towards the viewer, though, as can be concluded from the placing of the ears. So perhaps the Elephand should show the second tusk. I should take account of that in the Camel design too.

The Chessville Archbishop is a great symbol, but somehow it reminds me more of a Nazi officer that of a piest... I dislike putting additional Knight symbols in Knight+something pieces.

I would have to think how to implement Allessandro's advice. The stirrups could of course be hanging from a band, extending to the piece. But perhaps the stirrups are a bad idea in the first place, as they have a look-through hole in them, which might get filled up with white or black, making them look like solid objects. I tried a saddle, but I could not draw a recognizable one without disharmonizing perspective.

Perhaps a riding whip would do the trick:

Image

Top: Commoner, Ferz, Camel
Bottom: Amazon, Marshall, Centaur


The Nightrider above is approximately what I want, except the stripes there are too ambiguous for Nightrider vs Zebra distinction. So for the Nightrider the horizontal stripes should a bit more towards the right, behind the neck, while for the Zebra they would be on the neck and diagonal. (An alternative for the Nightrider that I once saw was to make it an ordinary Knight symbol, but wearing a "Zorro" mask.)
neoliminal wrote:Is that board you are showing me there the right size?

does it use .gif with transparent backgrounds or .png?
I know nothing of the design of fonts, and the Ultima board is simply a drawing I made with Power Point, and converted to bitmap by copy/pasting it into Paint (after having shrunk it to the desired size in Power Point), and saved it from there as jpg.

Same for the other sketches.
neoliminal

Re: Would someone be interested in programming....

Post by neoliminal »

Ok, I'll do some research.