In general what one would have to supply is a move set for every square, and that for every piece type, as not in every variant we will be so lucky that Numskulls and Ninnies on the same square must also move in the same directions.
This is along the same lines as an idea I had when I woke up during the night. My idea is that you could incorporate some kind of select-case structure into a move definition that allows you to use different Betza codes for the piece on different spaces. Using the Numskull as an example, it might start out something like this:
This is along the same lines as an idea I had when I woke up during the night. My idea is that you could incorporate some kind of select-case structure into a move definition that allows you to use different Betza codes for the piece on different spaces. Using the Numskull as an example, it might start out something like this:
For the sake of a game like Xiangqi, you could allow the use of wild cards in designating coordinates. So a Pawn definition might look like this:
Here the * functions like default in a select-case statement by coming at the end.