Check out Glinski's Hexagonal Chess, our featured variant for May, 2024.


[ 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 by ChessShogi

EarliestEarlier Reverse Order LaterLatest
Home page of The Chess Variant Pages. Homepage of The Chess Variant Pages.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Mon, Oct 3, 2022 10:51 AM EDT:

Now GC's legal moves aren't displaying for some pieces in the GC presets that display legal moves.

Edit: GC legal move highlights are working again.


A. M. DeWitt wrote on Mon, Oct 3, 2022 01:55 PM EDT:

GC preset legal move highlights work correctly now.

However, now you can't edit comments you are the author of.

Edit: it works now.


A. M. DeWitt wrote on Wed, Oct 5, 2022 03:55 PM EDT:

GC presets are not displaying at all now.

Edit: The presets will only load when an invitation to play a game has yet to be accepted. or when the preset was authored by Fergus Duniho.


A. M. DeWitt wrote on Wed, Oct 5, 2022 08:00 PM EDT:

It seems it's now impossible to delete a submission, even when said submission is completely empty (which is the normal requirement for using the deletion script). I temporarily revived Mitsugumi-Shogi to get an introduction for Mitsugumi Shogi's new page from one of the old page's revisions and then emptied the old page's contents. I then tried to delete it, but that didn't work.

If I could have an editor delete my Mitsugumi-Shogi submission that would be great. Note the hyphen in between "Mitsugumi" and "Shogi"!


A. M. DeWitt wrote on Wed, Oct 5, 2022 08:07 PM EDT in reply to Joe Joyce from 04:52 PM:

Hope this game can be retrieved as it's the one I'm not losing in!

I think it's more a problem of the preset not loading at all rather than a problem of retrievability. The game should still be in the database.


A. M. DeWitt wrote on Thu, Oct 6, 2022 10:38 AM EDT in reply to Máté Csarmasz from 01:27 AM:

I have a broken game (Modern Makruk).

The game isn't broken. The preset is not loading. I had the same problem when trying to update Mitsugumi Shogi's preset.


A. M. DeWitt wrote on Thu, Oct 6, 2022 01:14 PM EDT:

GC presets are working again.

The deletion script for submissions is still not working properly though.


Suzumu Shogi. 16x16 variant based on Tenjiku Shogi. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Thu, Oct 6, 2022 05:36 PM EDT:

The GC preset is no longer up to date. I still need to work out the kinks of the contagious promotions.


💡📝A. M. DeWitt wrote on Thu, Oct 6, 2022 07:06 PM EDT:

I have fixed the GC preset's contagious promotions and clarified the rules for contagious promotions as well.


Home page of The Chess Variant Pages. Homepage of The Chess Variant Pages.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Fri, Oct 7, 2022 07:47 AM EDT:

I cannot delete a submission that I want to delete, even though said submission is empty. I temporarily revived it (the old Mitsugumi Shogi page) to get something for the new page and then tried to delete the former, but the delete script doesn't work.

Edit: Now it is impossible to update a submission to an empty page, which is a requirement for deletion.


Suzumu Shogi. 16x16 variant based on Tenjiku Shogi. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Fri, Oct 7, 2022 11:07 AM EDT:

I've been working on reviving this game (and Mitsugumi Shogi), and pretty much everything is done, but I am not sure how I should handle trading of the Fire Demons in these games to keep them exciting. Such rules don't really matter in Tenjiku Shogi, as the Tenjiku Fire Demon burns every adjacent enemy piece every time it moves, and even on the opponent's turn, so you can easily get several pieces for the price of one. In Suzumu Shogi (and Mitsugumi Shogi), the Fire Demon moves like a Free Boar with an additional area move and can optionally shoot one adjacent piece, either without moving or after it stops, and has no passive burn (XBetza: shQshympacabQ(a)2KmcabK(a)2mpacabK). In other words, the Suzumu Fire Demon's burning move is much weaker, potentially requiring rules to conserve it until the very end of the game.

I thought about implementing Chu Shogi-style rules for this, but they don't really work for a piece like the Suzumu Fire Demon. I then thought about implementing Maka Dai Dai Shogi's contagious promotion rules as well, but I worried that it would make the Fire Demons too survivable.

Right now I have a more limited contagious promotion rule in place which only affects direct captures of a Fire Demon or Heavenly Tetrarch from pieces that are not (potential) royals. I also gave the Suzumu Fire Demon's burning ability to the Heavenly Tetrarch. The former ensures that at least one Demon/Tetrarch survives, and the latter makes the Chariot Soldier more dangerous to make up for the weakened burning move. I think these changes work quite well, but I still want an outside opinion on this to make sure I am dealing with this issue the right way.


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sat, Oct 15, 2022 09:45 AM EDT:

Quick question: Does the diagram AI take into consideration the highlight restrictions from the BadZone function? I was thinking about reviving Suzumu Shogi and adding a rule forbidding pieces that burn from burning each other, and I have successfully defined a BadZone function to enforce it in the move highlights, but I worry that it won't be take into consideration by the AI. I tested it on my own interactive diagram, and it seems to work.


Game Courier Developer's Guide. Learn how to design and program Chess variants for Game Courier.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sat, Oct 15, 2022 10:43 AM EDT:

What should I use if I want to test for past and potential captures and have captures of certain pieces always return false in a function definition?

I know how to do it for general captures.

cond empty #0 capture (not empty #1)

Perhaps this?

cond empty #0 (not match old FD +WB +CS) (not match space #1 FD +WB +CS)


Suzumu Shogi. 16x16 variant based on Tenjiku Shogi. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Sat, Oct 15, 2022 11:49 AM EDT in reply to Daniel Zacharias from Mon Oct 10 08:02 PM:

I think there's a problem with the current preset. The knights aren't able to move sideways or backwards.

Thanks for catching that. I will fix that right away.

I've decided that the contagious promotions made the Fire Demons too survivable, and instead went with a rule that prevents Fire Demons and Heavenly Tetrarches from burning each other. That way trades can still happen, but it's not super easy to do so. And because of the high number of pieces that promote to these two juggernauts (4 Chariot Soldiers and 2 Water Buffalos per side), and the fact that they start in very survivable positions, there will likely be at least one such piece left when the board is depleted enough that said piece can take advantage of holes in the opponent's defenses.


Game Courier Developer's Guide. Learn how to design and program Chess variants for Game Courier.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sat, Oct 15, 2022 09:29 PM EDT in reply to Fergus Duniho from 12:36 PM:

Recently I revived Suzumu Shogi and Mitsugumi Shogi and added a rule to them forbidding burning pieces (Fire Demons and Heveanly Tetrarches) from burning each other. To enforce this in the GC presets, in theory all I need to do is, on the burning move, make sure that the capture (past and potential) doesn't equal those pieces in the relevant function definitions.

If I need to test for a general capture in this situation, that is pretty easy: cond empty #0 capture (not empty #1). By extension, for ensuring a burning piece isn't captured I would, in theory, need to use cond empty #0 (not match old FD +WB +CS) (not match space #1 FD +WB +CS) in the part of the piece function used for the burning moves. The "FD +WB +CS" part is the ids of the burning pieces.

The second output for the cond statement works fine, but the first doesn't. I think what I need is something that will return the value of old at the time the function is called.

Here is the preset link for Suzumu Shogi in case you need to look at the code: Suzumu Shogi on the Chess Variants Game Courier

 


A. M. DeWitt wrote on Sun, Oct 16, 2022 09:43 PM EDT in reply to Fergus Duniho from 01:11 PM:

So perhaps I just need to put sub FD #0 #1 after the test (I tend to forget GC executes from right to left)?

Edit: That didn't work. I guess I'll just stick to the tried and true method of using the bpromote and wpromote subroutines for the actual rule enforcement.

I am curious though: if you use old in a function definition, does it return the value at the time of the function definition or the function call?


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Oct 18, 2022 01:42 PM EDT:

For some reason, when promoChoice is set to + for Shogi-style promotions, the piece names in the table don't show the promoted version when clicked a second time.

Edit: This is only true for the table that shows the selected piece.


A. M. DeWitt wrote on Wed, Oct 19, 2022 10:59 AM EDT in reply to H. G. Muller from Tue Oct 18 03:48 PM:

The problem was fixed when you fixed the piece promotion not showing. The extra satellite functionality for user defined functions is also quite nice.


Home page of The Chess Variant Pages. Homepage of The Chess Variant Pages.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Thu, Oct 20, 2022 07:24 PM EDT:

Apparently, the site will not allow you to have an empty submission, which is required for the deletion script to work.


New Submissions for Review. A listing of all submissions still awaiting editorial approval.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Mon, Oct 24, 2022 11:10 AM EDT:

Suzumu Shogi and Mitsugumi Shogi (Rules pages and GC preset pages) are ready.

The Heavy Shako GC preset page is also ready.

Mitsugumi-Shogi (Note the hyphen!!!) can be deleted.


Home page of The Chess Variant Pages. Homepage of The Chess Variant Pages.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Oct 25, 2022 10:53 AM EDT in reply to Diceroller is Fire from Fri Oct 21 07:56 PM:

That's what the Revisions page is for (in the top menu, Edit -> N revisions). Click the revision you want to select, press Ctrl-U to view the source code. You can then copy the relevant HTML sections into the editors in the Edit Page form.


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Nov 15, 2022 04:51 PM EST:

I hope triple captures besides those of the Lion Dog become a thing in the future. Perhaps by using two additional variables ex2 and ey2? It shouldn't be too hard, at least for updating the functions that use the variables for the move coords to use the and updating the code for highlights, though I could be wrong. If it becomes too complicated for the AI there's always the enableAI=0 option.


A. M. DeWitt wrote on Tue, Nov 15, 2022 07:40 PM EST in reply to H. G. Muller from 05:08 PM:

That's perfect! Now that that's done, I can test a double-burning Suzumu Fire Demon.

Also, for some reason the Comments section is excessively narrow when viewed from the interactive diagram page.


Suzumu Shogi. 16x16 variant based on Tenjiku Shogi. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Tue, Nov 15, 2022 10:12 PM EST:

Now that triple captures other than those of the Lion Dog are supported by the interactive diagram, I am currently testing a new version of Suzumu Shogi, with burning pieces (Fire Demons and Heavenly Tetrarches) that can burn (or capture without moving as in igui) up to two adjacent pieces at once.


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Wed, Nov 16, 2022 10:21 PM EST:

One other question: how will the new move generation affect the pieceZone and piecePromotion functions (and other functions that use parameters representing move coordinates)? The new code does not appear to use the old variables that keep track of a move's coordinates. Instead a clicks array is used to store the coordinates for every clicked square in one variable. For obvious reasons, the old parameter list for pieceZone and piecePromotion wouldn't really work all that well.

Also, you should consider adding a section about the user-defined functions so people don't have to read the comments to figure out what they do.


A. M. DeWitt wrote on Thu, Nov 17, 2022 07:45 AM EST in reply to H. G. Muller from 12:53 AM:

Diagram parameters would be ideal, but there's one little problem. When rule enforcement require complex decision making (such as in Suzumu Shogi's current version, which forbids burning pieces from burning each other) the diagram parameters would be less than ideal. So there would likely still be a need for such functions even if the parameters eliminate the majority of cases where they would be needed.

I'm not sure how you intend to merge move rejection, game termination, mandatory promotion, and offering promotion choice, into a single function, unless JS allows you to return a value that could be one of many different types.

But I suppose it is better to stick to perfecting the new move generation system for now and focus on the functions later in development.


A. M. DeWitt wrote on Thu, Nov 17, 2022 08:15 PM EST:

It seems that the holdings do not work correctly. Whenever holdingsType is set to anything other than 0, for each piece, it subtracts the amount on the board from the amount present at the start of the game rather than showing the actual amount in the hand. Also, setting holdingsType to -1 does not change the color for Shogi drops like it should.


A. M. DeWitt wrote on Fri, Nov 18, 2022 08:52 AM EST in reply to H. G. Muller from 01:36 AM:

It is now fixed.  However, I also noticed that promoted pieces are affecting the hand when they shouldn't, particularly for Shogi-style promotions (increments original, decrements promotion).


A. M. DeWitt wrote on Fri, Nov 18, 2022 12:11 PM EST in reply to H. G. Muller from 10:56 AM:

Nice.


Suzumu Shogi. 16x16 variant based on Tenjiku Shogi. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Fri, Nov 18, 2022 03:27 PM EST:

I have finalized the double burning version of Suzumu Shogi, and by extension, Mitsugumi Shogi. I might reintroduce the ban on burning pieces with burning moves in the future, but the current version of the diagram does not have the tools needed to do that.

The GC presets are no longer up to date.


Mitsugumi Shogi. Smaller variant of Suzumu Shogi on a 13x13 board. (13x13, Cells: 169) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Fri, Nov 18, 2022 08:30 PM EST:

Mitsugumi Shogi is ready


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sat, Nov 19, 2022 05:26 PM EST:

It seems that the new move handler isn't updating the part of the diagram that shows which piece is selected.


Game Courier. PHP script for playing Chess variants online.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sat, Nov 19, 2022 08:57 PM EST:

I am having problems with my new preset for Suzumu Shogi. For some reason, it just keeps echoing "Please report any bugs or errors to Adam DeWitt" over and over again instead of showing the preset like it should. Any help would be greatly appreciated.


Suzumu Shogi. 16x16 variant based on Tenjiku Shogi. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Sat, Nov 19, 2022 11:39 PM EST in reply to H. G. Muller from 01:01 AM:

I was thinking banning burning Fire Demons and Heavenly Tetrarches (possibly allowing it if something else is burned first), but allowing these pieces to be captured directly or via igui (the latter which is a locust capture). I tried doing it with the BadZone function used in the last version, and most of the time it worked perfectly, but for some reason the part testing for the evic parameter value would cause the area move (and sometimes non-capture moves) to disappear if two burning pieces were within burning distance of their orthogonal ranging moves. Right now, I am happy with the current version. Fire Demons can still be traded, but at least now it is easier for the moving Fire Demon to grab an additional piece without risking recapture thanks to the strengthened burning ability.


Game Courier. PHP script for playing Chess variants online.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sun, Nov 20, 2022 08:01 AM EST in reply to Fergus Duniho from 01:53 AM:

I guess I didn't make the link clear enough (Edit: Suzumu Shogi on the Chess Variants Game Courier). What I have should work. I don't see any typos in the code. But of course I'm probably overlooking something.

Edit: I found it. Turns out the remind messages in the Post-Game sections had typos in them.


A. M. DeWitt wrote on Sun, Nov 20, 2022 10:12 AM EST in reply to Fergus Duniho from 08:32 AM:

I fixed most of the issues. Now the only problem that I can see is that the Heavenly Tetrarch's first burn is being rejected when it shouldn't be when the distance between the origin and destination of the first part of the move is at least 2. The problem is likely in the HT subroutine, since it controls the function definition for the second and third parts of the Tetrarch's move, but I could be wrong.

Here is the link for the preset's Edit form: Edit: Suzumu Shogi on the Chess Variants Game Courier

And here's the list of moves for which the error occured:

1. d 8k-8j 
1... D 9f-9g 
2. p 7l-7k 
2... P 10e-10f 
3. bg 6m-8k 
3... BG 11d-9f 
4. fd 7n-6k 
4... FD 10c-11f 
5. fd 6k-8i 
5... FD 11f-9h; pass 
6. fd 8i-5f; fd 5f-5e; fd 5e-4e 
6... FD 9h-12k; FD 12k-12l; FD 12l-13l 
7. fd 5f-7f; pass 
7... FD 12k-10k; pass 
8. fd 7f-7e; fd 7e-7f; fd 7f-8f 
8... FD 10k-10l; FD 10l-10k; FD 10k-9k 
9. bg 8k-15d; +bg-dest 
9... BG 9f-2m; +BG-dest 
10. dk 5n-5o 
10... DK 12c-12b 
11. cs 4o-14e; +cs-dest 
11... CS 13b-3l; +CS-dest 
12. +cs 14e-14d; +cs 14d-14e; +cs 14e-13d 
12... +CS 3l-3m; +CS 3m-3l; +CS 3l-4m 
13. +cs 14e-11b; +cs 11b-10a // <- ERROR: You may not move a +cs from 11b to 10a

A. M. DeWitt wrote on Sun, Nov 20, 2022 11:55 AM EST in reply to Fergus Duniho from 11:41 AM:

That was what I was thinking as well, and given that the rest of the code is fine, we are probably right. Unfortunately, simply getting rid of that clause won't really solve the issue. The Heavenly Tetrarch has a unique mechanic that causes it to jump over the first square it travels over, so the preset needs to take that into account. It might be possible to get rid of it with clever use of the cond statemenet though.

Edit: Turns out I was using the wrong variables to account for the distance of the first part of the move. The values of origin and dest were updated before the move was evaluated, so the distance would always be 1 and the move would thus get rejected. I fixed this by using ori and dst instead, which stay the same for all parts of the move.


Suzumu Shogi. 16x16 variant based on Tenjiku Shogi. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Sun, Nov 20, 2022 08:06 PM EST in reply to H. G. Muller from 11:45 AM:

Yes, (though this extends to burning pieces in general) and the BadZone code from the last version mostly worked (if you include "in addition to burning another piece"), but like I said earlier, the section testing the evic value (the intermedate square) caused parts of the Demon's area move to disappear when they were within one rank of each other, so I decided to just remove the restriction altogether so I didn't have to worry about it. I think I'll wait until the new function that combines BadZone, WeirdPromotion, etc. is finished.


💡📝A. M. DeWitt wrote on Mon, Nov 21, 2022 03:58 PM EST in reply to H. G. Muller from Sun Nov 20 11:45 AM:

I can make a revision with the BadZone code in it if you want.


💡📝A. M. DeWitt wrote on Mon, Nov 21, 2022 07:23 PM EST in reply to H. G. Muller from 04:14 PM:

Here is the BadZone function's code:

function badzoneZone(x2, y2, piece, color, x1, y1, ex, ey) {
  if(touched) return 0; // not during ShowMoves()
  if(piece == 35 || piece == 65 || piece == 66) // Fire Demons and Heavenly Tetrarches
  {
    evic = (ex >= 0) ? board[ey][ex] & 511:-1;  // intermediate square
    if(evic == 35 || evic == 65 || evic == 66) { // Problem area
      if((x1 == x2 && y1 == y2) || (ex == x2 && ey == y2)) return 0; // Allow direct capture or igui
        else return 1; // else reject
      }
    }
    return 0;
  }
}

Eventually I hope to make it so that burning pieces cannot burn each other at all.

You can view a diagram with this function implemented here.


💡📝A. M. DeWitt wrote on Thu, Dec 8, 2022 07:00 PM EST:

Suzumu Shogi is ready


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Fri, Dec 9, 2022 06:03 PM EST:

The part of the wizard where you add pieces to the board is still broken. The board shows up, but nothing else.


Tenjiku Shogi. Fire Demons burn surrounding enemies, Generals capture jumping many pieces. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Wed, Dec 14, 2022 07:03 PM EST:

I wonder how the game would be different if the jumping Generals instead had range capturing moves like their Taikyoku Shogi cousins?


Game Courier. PHP script for playing Chess variants online.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Fri, Dec 16, 2022 08:28 PM EST:

There seems to be a bug with the checkahop operator, in that it seems to allow both the hop in the intended direction and the hop in the opposite direction, at least on the second part of a multi-move. This can be demonstrated in this game of Suzumu Shogi (the experimental version w/ triple capturing versions of the jumping Generals)

1. rg 7m-7d; +rg-dest 
1... RG 10d-10m; +RG-dest 
2. wb 11n-12o // begin setup for bug demo
2... WB 6c-5b 
3. +rg 7d-6c 
3... +RG 10m-11n 
4. fe 8m-10m 
4... FE 9d-7d 
5. lh 9m-8k 
5... LH 8d-9f 
6. d 12k-12j 
6... D 5f-5g 
7. d 12j-11k 
7... D 5g-6f 
8. p 14l-14k 
8... P 3e-3f // end setup for bug demo
// in this position, when +rg 7c is clicked after 9. +rg 6c-7c, it shows the two intended hops plus another (unintended) hop on 4c which jumps over the first piece in the opposite direction, which is incorrectly accepted by the rule enforcement code.

I'm pretty sure this is a server-side bug and not a bug involving my code. Any help would be much appreciated.


A. M. DeWitt wrote on Sat, Dec 17, 2022 08:49 PM EST in reply to Fergus Duniho from 05:12 PM:

Thanks for fixing checkahop.

As for the rest of the RANGECAPTURE code, the not so compact cx and cy assignments were me trying to fix the bug before realizing it was a server-side issue. I can just use cmp there since the jumping Generals can only jump along the eight cardinal directions. Since they use #ori and #dst (the variables that store origin and dest), and the jumping Generals cannot change direction mid-move, there is no need to compare directions, as using cx and cy with checkaride and checkhop returns the same direction as that of the first part of the move. The if statement with the checkaride clause is there to enforce the two jump limit for these pieces. If that checkaride clause fails but the ismultimove subroutine succeeds, the moving pieces has jumped over a piece (and another piece which it just captured) already, and thus cannot jump any more pieces.


A. M. DeWitt wrote on Sun, Dec 18, 2022 10:06 AM EST in reply to Fergus Duniho from Sat Dec 17 10:04 PM:

Fair enough.


A. M. DeWitt wrote on Mon, Dec 19, 2022 09:25 AM EST in reply to Fergus Duniho from Sun Dec 18 09:01 PM:

It seems I had an extra parameter in the israngecapture subroutine from when I was trying to use a subroutine to determine whether a range capturing piece had any legal moves left mid-move. It is fixed now. The responsibility of determining whether a piece has any moves left mid-move has been moved to the Post-Game sections, making use of the legalmoves2 subroutine's return value. I also fixed Mitsugumi Shogi's GC preset, which had the same problem.

Edit: I also got rid of the from parameter in the israngecapture subroutine and the statements that call it. Since it wasn't being used within the subroutine itself, there was no need to include it in the parameter list.


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Dec 20, 2022 10:23 PM EST:

It seems there is a bug affecting certain XBetza moves enclosed in parentheses that prevents their highlights from displaying properly. For example, this bug will show up after executing the following moves in Suzumu Shogi's interactive diagram:

1. HFmm11 HFxm12xm13+

After promoting the Falcon to Bishop General (XBetza (cmpaf)2cBmcB), click on it and then click on the Lance in the corner. If done right, the highlights for the second part of the move will not show up at all.

The bug seems to be coming from this line in the NewClick function:

        var h = hlights[k], victim = board[h[1]][h[0]], col = ((h[3] & 3) == 1 ? h[3] & 64 ? '#00C000': '#00FF00' : h[3] & 64 ? '#C0C000' : '#FFFF00');

Any help fixing this would be greatly appreciated, as I could potentially reduce the length of the most complicated Suzumu piece's Betza strings significantly.


Variants playable against the diagram's AI. (Updated!) Index of variants that can be played against the interactive diagram.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Wed, Dec 21, 2022 10:45 PM EST:

Suzumu Shogi and Mitsugumi Shogi have been moved to different pages. There is no longer a hyphen separating the words "suzumu/mitsugumi" and "shogi," so if those could be updated that would be greatly appreciated.

Also, Hanten Shogi and Gyaku-sama Shogi no longer exist, so they can be removed from the list.


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Thu, Dec 22, 2022 03:23 PM EST in reply to H. G. Muller from 07:43 AM:

Yes, using cpaf instead of cmpaf does work, but only if it used once. (cpaf)2cB only covers a subset of the moves that (cmpaf)2cB covers. Remember, the p and a modifiers exclude the m modality if only c and/or d are specified in the modifiers immediately before it, per their definitions. Thankfully, this problem can easily be solved by writing the missing legs separately, yielding B(cpaf)2cBcafpafcBpafcafcB. Longer for sure, but it won't have the same search explosion problem, at least for the (cpaf)2 part. The other two multi-leg parts may have search explosions since paf is (usually) equivalent to mpaf (which can lead to the same problem as before), but they will be much more subtle explosions since paf is only used once.

I will update the diagram at the page I used to demonstrate the Suzumu Shogi BadZone bug (which can be found here) to include this bug, for future reference.


Betza notation (extended). The powerful XBetza extension to Betza's funny notation.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Thu, Dec 22, 2022 10:37 PM EST in reply to H. G. Muller from Thu Nov 17 04:55 AM:

I have implemented k now such that in combination with c it disables capture of royals. (A combination that before was not different from plain c.)

Actually this means that k now can do what the t modifier (for 'tame') does in XBoard. Without using an extra letter!

That's fantastic. Brings Tenjiku Shogi one step closer to being implementable in an interactive diagram. The range jumping piece's moves (in this case the Bishop General) can now be written as B(paf)0ckB, where ck takes care of the restriction against capturing royals by jumping. The current BadZone function could easily handle the rest of  the rankings for the jumping Generals. Now just to figure out what to do for the burn...and how to specify options to accomodate how the burning move behaves. Once I have a way to do this, I can take care of the rest.


A. M. DeWitt wrote on Fri, Dec 23, 2022 11:46 AM EST in reply to H. G. Muller from 02:16 AM:

BTW, I have played Tenjiku at high level according to 'modern' rules, where the King can be jump-captured. To my surprise this was very playable, and not too unbalanced. If you know the correct opening lines. Which my Tenjiku engine was able to determine.

In addition I came to realize that the King has highest rank does not necessarily have to refer to capture. Originally I thought that outlawing jumping over a King only would be pointless, as you would never be interested in doing that when you could also capture it. But it could also refer to your own King. So the evidence that historic rules did not allow King capture is starting to get flimsy.

Jumping Generals are not allowed to jump over a King or Prince (or other higher-ranking pieces) of either side, regardless of which ruleset you use, so the fact that the rankings could refer to friendly pieces is a rather dubious piece of evidence for allowing jump-captures of royals. Besides, even if the evidence for forbidding jump-captures of royals is indeed flimsy, it still improves the gameplay, as allowing jump-capturing of the King creates a critical weaknesses in the opening after 1. 7k (2. VG 2g#) which is only solvable via 1... SE3f. Furthermore, this weakness persists throughout much of the game, as the King remains boxed in throughout the opening and (early) middlegame, the Soaring Eagle on 3f (and other pieces defending 2g and 1h) can easily be threatened with capture, and one wrong move can result in a smothered mate. The point is, you should not need to use an AI to find a good opening.

Unfortunately this is not so easy, because BadZone only gets the locust squares passed. Not the pieces jumped over. The non-destructive intermediate squares are not part of the internal move representation. But I suppose BadZone could be made such that it scans the board for high-rank blockers along the path from origin to destination itself.

You can just use board[y][x] & 511 for the piece type, and a call to a recursive function that scans the in-between squares to handle the rest.


A. M. DeWitt wrote on Fri, Dec 23, 2022 01:58 PM EST in reply to H. G. Muller from 12:11 PM:

Ok, fair enough.


Tenjiku Shogi. Fire Demons burn surrounding enemies, Generals capture jumping many pieces. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Fri, Dec 23, 2022 02:07 PM EST in reply to H. G. Muller from Thu Dec 15 05:17 AM:

Yeah, that doesn't seem like a good idea.


Game Courier Developer's Guide. Learn how to design and program Chess variants for Game Courier.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sat, Dec 24, 2022 09:38 PM EST:

This  is probably a stupid question, but can a subroutine have zero parameters?

Example:

sub <subname>;
  <...code...>
endsub;

A. M. DeWitt wrote on Sun, Dec 25, 2022 11:24 AM EST in reply to Fergus Duniho from Sat Dec 24 09:53 PM:

Ok. Thanks.


A. M. DeWitt wrote on Fri, Dec 30, 2022 10:14 PM EST:

When using the allow command, am I correct that the word in the word/number argument pair does not have to be a command or keyword?

Example:

allow ... one 2 two 2 onetwo 2 ...; // I was planning on using this to get around a very annoying bug I found in a future version of Suzumu Shogi's GC preset (with multi-capturing versions of the jumping Generals).

Edit: I answered my own question. You can use custom commands in allow, provided that for each custom command you include a subroutine in your Pre-Game code like the one shown below.

sub <cmdname>:
  return true;
endsub;

Tenjiku Shogi. Fire Demons burn surrounding enemies, Generals capture jumping many pieces. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sun, Jan 1, 2023 10:59 AM EST:

Do you want to update this page to remove the rule that the jumping Generals cannot jump-capture royalty?

Note: My presets for Tenjiku Shogi and Nutty Shogi follow the rules described in their respective Rules pages, so they will not be changed unless you update them.


Home page of The Chess Variant Pages. Homepage of The Chess Variant Pages.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Jan 3, 2023 11:31 AM EST:

For some reason, when using an image for the board in Game Courier, the file labels are positioned higher than they should be. Here's an example from Chu Shogi.


Tenjiku Shogi. Fire Demons burn surrounding enemies, Generals capture jumping many pieces. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Jan 3, 2023 01:14 PM EST in reply to H. G. Muller from 11:36 AM:

Well, I don't want to have any discrepancy between what is in Wikipedia and on CVP, so I would then also have to change it in Wikipedia. To not run into an edit battle there, this would have to be done with care.

Understandable. I don't think this would be too hard, provided that the forbidding jump-capturing royalty rule is mentioned in the Disputed Moves section along with a reason for the change (perhaps your comment from our conversation in the Betza notation (extended) page?). But then again, maybe the Wikipedia page is far more sensitive to rule changes than I think it is.

All other rules equal, this would make for a very interesting game.


Zo Shogi (象將棋). A variant of Sho Shogi in which Drop rule is included and Prince (promoted Elephant) is a non-royal King. (9x9, Cells: 81) [All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Jan 3, 2023 09:05 PM EST:

You have some great ideas. However, you seem to have some difficulty when trying to put those ideas in words. Thankfully I'm here, and I have plenty of tips from personal experience with using the site.

Here's some of those tips to get you started.

  • Put important statements (such as "All rules are identical to standard Chess except for the following") at the top of the section they go in. This makes reading about the differences more intuitive, as the top of the section is the first thing the reader will see. The same goes for the page in general.
  • Put the Interactive Diagram for the game in the Setup section along with the picture, preferably above the picture. This way the reader can dive right in without having to scroll down to the comments section. This helps the reader understand your game more quickly.
  • Using tables in the Pieces section works wonders for helping the reader to understand your game better, and has the added benefit of making the Pieces section look nicer in general.
  • Make sure to respond to comments that editors make in a timely fashion. This speeds up the publishing process
  • Be patient. There are only a handful editors on the site, and only some of them will be processing submissions at any given time, so it may take a while to get your submissions published, even if you do everything right the first time. Case in point, the GC preset pages for Suzumu Shogi and Mitsugumi Shogi have been approved, but the corresponding Rules pages have not (which I find a bit odd, but I digress).
    • You can leave a comment on this page if you think they missed your submission, but do this sparingly.
  • Don't be afraid to ask for help! There are plently of contributors and editors on the site who are more than willing to help you if you just ask them.

A. M. DeWitt wrote on Wed, Jan 4, 2023 08:12 PM EST in reply to Daphne Snowmoon from 09:38 AM:

And I'm not sure exactly what the 'table' you are talking about is

When I say tables, I am referring to HTML tables. Speaking of which, it wouldn't hurt to get to know the basics of HTML, if you haven't done so already.

The editor also allows you to insert tables without needing to write HTML.

But I don't know how to apply interactive diagram inside the page.

All you need to do is paste the diagram definition into the page. The Interactive Diagram script doesn't care where you put it - the result is the same. Depending on whether there are multiple diagrams on the page, you may need to set the satellite parameter (satellite=xxx) within the definition to get it to work.

IMPORTANT: When inserting or editing an interactive diagram, make sure you keep the editor in HTML format, otherwise the editor will mess up the definition!


Suzumu Shogi. 16x16 variant based on Tenjiku Shogi. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Tue, Jan 10, 2023 11:20 PM EST:

After some testing, I found that the threat of the Great General capturing one of the Fire Demons was giving Black too big an advantage. So to keep the new range captures under control, the jumping Generals are now subject to the rankings from Tenjiku Shogi (may only jump lower ranking pieces, but no restrictions on final capture). Update coming soon to both the rules page and the GC presets.


💡📝A. M. DeWitt wrote on Tue, Jan 17, 2023 04:19 PM EST:

After some testing, I have managed to implement an algorithm to implement the Tenjiku ranking system in the interactive diagram. I've also changed the Heavenly Tetrarch's move so that instead of burning, it freezes (immobilizes) all adjacent enemy pieces except other Heavenly Tetrarches. Because of this, the Fire Demon's burning move restriction now only applies to other Fire Demons.

The GC Preset has already been updated, and the Mitsugumi Shogi preset will be updated soon.


💡📝A. M. DeWitt wrote on Tue, Jan 17, 2023 10:14 PM EST in reply to Daniel Zacharias from 08:14 PM:

Is that instead of burning? That's an interesting addition

Yep. It creates a nice duality between the the Fire Demon and the Heavenly Tetrarch. And it was really easy to implement for the interactive diagrams and GC presets thanks to this comment and GC's Ultima include file. The diagram now understands the new restrictions for the jumping Generals as well (same as Tenjiku, but with no restrictions on the final capture), though it still isn't yet capable of understanding the burning restriction. The GC presets are also up to date. But the best part is that I am finally done developing this game (for real this time). It took 4 years, but it was worth it.

The new freezing ability for the Suzumu Heavenly Tetrarch came from a suggestion by Eric Silverman somewhere about a certain version of the Tenjiku Heavenly Tetrarch having a similar ability instead of the igui ability, immobilizing adjacent pieces, and stopping an adjacent Tenjiku Fire Demon's burn (for all pieces adjacent to the Fire Demon) as well. I can't seem to find it anymore though...

Edit: I also cropped the Shogi images so that they are the same size as the Mnemonic images.

Edit: It seems I left out the double igui part of the Tetrarch's description. I'll fix that right away.

Edit: I also changed the turn skipping restrictions to be more in line with those of other LSVs (specifically, you cannot skip two consecutive turns, making skipping a turn useless if your opponent can skip their turn too)


💡📝A. M. DeWitt wrote on Wed, Jan 18, 2023 11:01 AM EST:

I think I have an idea of how to implement the burning restriction in the interactive diagram using the clicks array, which stores the values for each move made using the the new move system. It's going to take a while to perfect it though.

Edit: I managed to implement the burn restriction for Fire Demons that burn once in a prototype file. Now for the hard part...Fire Demons that burn twice.

Edit: Turns out the code from the first prototype covered a lot of the cases for the twice-burning Fire Demon. Now, the second prototype covers most cases. The only thing left is to allow a direct capture of a Fire Demon where the Fire Demon burns exactly twice.

Edit: After some struggling, I managed to cover all the cases for the twice-burning Fire Demon, which means the Diagram now properly forbids a Fire Demon from burning another Fire Demon. The Rules pages for Suzumu Shogi and Mitsugumi Shogi will be updated soon.

Edit: I've updated both pages. No more worrying about having the AI make an illegal move.

Edit: It turns out the AI's move generation doesn't use the clicks array, so the AI will exit with an error whenever you try to run it.

Edit: With some help from H. G. Muller, I was able to fix the burning restriction for the AI.


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sat, Jan 21, 2023 10:20 AM EST:

I'm having a problem with Suzumu Shogi's interactive diagram. I managed to get the Fire Demon's burning restriction implemented properly in the pieceZone function using the clicks array, but as it turns out, clicks is not used by the AI's move generator, so the AI doesn't work properly. I was wondering if there is a similar array used by the AI to keep track of the squares it visits?

In case you need it, here is the relevant portion of the pieceZone code and its supporting functions (I left the rest out, since it is quite complicated)

function pieceZone(x2, y2, piece, color, x1, y1, ex, ey)
{
  if(touched) return 0; // not during ShowMoves()
  // ... Heavenly Tetrarch Section ...
  // Fire Demon
  v = board[y2][x2] & 511; // Highlight square
  firstX = (clicks.length >= 4) ? clicks[2] : -1;
  firstY = (clicks.length >= 4) ? clicks[3] : -1;
  firstVictim = (clicks.length >= 4) ? board[firstY][firstX] & 511 : -1;
  secondX = (clicks.length >= 6) ? clicks[4] : -1;
  secondY = (clicks.length >= 6) ? clicks[5] : -1;
  secondVictim = (clicks.length >= 6) ? board[secondY][secondX] & 511 : -1;
  if(isBurner(p))
  {
  // Always allow starting square
  if(x2 == x1 && y2 == y1) return 0;
  // Reject captures of Fire Demon outside normal range
  if(isBurner(v) && !nonBurningRange(x1, y1, x2, y2)) return 1;
  // Allow direct capture of Fire Demon with second burn after first burn
  if(firstVictim > 0 && !isBurner(firstVictim) && clicks.length == 4)
  {
    if(isBurner(v) && nonBurningRange(x1, y1, x2, y2) && canBurn(x2, y2, firstX, firstY)) return 0;
  }
  // If first victim is a Fire Demon, allow move to start square, reject moving to empty square or burning another Fire Demon
  if(isBurner(firstVictim))
  {
  // Always allow starting square
  if(x2 == x1 && y2 == y1) return 0;
    // If a Fire Demon was captured via igui, always allow second burn of Fire Demon
    if(isBurner(firstVictim) && secondX == x1 && secondY == y1) return 0;
      // if second victim is not an empty square or a Fire Demon, only allow single burn
      if(secondVictim > 0 && !isBurner(secondVictim)) return !(x2 == secondX && y2 == secondY);
      // Reject moves to empty square or burn of Fire Demon
      else return (v == 0 || (isBurner(v) && (x2 != firstX || y2 != firstY)));
    }
    // If first victim is not a Fire Demon, allow direct capture with optional second burn, reject burn of another Fire Demon
    else
    {
      if(firstVictim != -1 && !isBurner(firstVictim))
      {
        if(isBurner(v)) return 1;
      }
    }
  }
  // ... Range Capturing Pieces Section ...
  return 0;
}

A. M. DeWitt wrote on Sat, Jan 21, 2023 07:05 PM EST in reply to H. G. Muller from 11:26 AM:

Very useful information. Unfortunately it requires me to go back to the drawing board...


A. M. DeWitt wrote on Sat, Jan 21, 2023 11:42 PM EST:

Unfortunately, I wasn't able to find a solution for implementing the burning restriction for the AI other than disabling the AI. It mainly has to do with the fact that the move generator will auto-complete the move if it thinks only one move is left if I try to use the killX and killY arrays instead of the clicks array.


A. M. DeWitt wrote on Sun, Jan 22, 2023 09:30 AM EST in reply to H. G. Muller from 05:32 AM:

I think it is better to just show you the difference. You can find the demonstration diagrams here.


A. M. DeWitt wrote on Sun, Jan 22, 2023 08:20 PM EST in reply to H. G. Muller from 03:54 PM:

I did notice that the kills variable wasn't being updated upon selection of a locust victim when I did some debugging of my own. The killX and killY arrays would update, but kills would always be zero. That would explain why when I tried recreating the clicks array using the visits array (using kills to regulate the length of the killX and killY arrays), it always ended up failing.


A. M. DeWitt wrote on Mon, Jan 23, 2023 01:43 PM EST in reply to H. G. Muller from 04:27 AM:

Some other remarks: You use (af)0 to force a slide on a K atom, but this is not recommended. Because (af)0K is expanded by pre-processing to KafKafafKafafafK..., as if every distance is a separate move, which would be attempted independently. So if the slide is blocked at the second square (so that afK would fail to produce a move) it would still keep trying afafK etc. And when afafafK was a valid non-capture, it would still again check the first four squares for emptiness when attempting afafafafK and longer paths. The equivalent plain Q would do much more efficiently, and probe each square on the path only once, and stop after it finds an occupied one. You can turn the Q into K for the burning by using ya to specify a range toggle. E.g. mpyacabQ would describe a Queen burning one enemy adjacent to her destination.

Sure, (af)0mpacabK is inefficient, but under the current implementation, it's the only Betza string that gives all options for the Fire Demon's burn. Using ympacabQ omits some of these options for some reason.

I suppose I should put the code that moves the destination click earlier inside a loop, so that it is able to pass locust vctims as lon as the preceding two legs have a cab structure. Then the double burnings could be entered by first clicking the destination, and then picking off the burn victims until you run out of victims, or click the destination again to terminate the move. That would be a much more intuitive way for entering multiple burns.

It would also make implementing the burning restriction much simpler, as then I don't have to worry about branching cases nearly as much, as it would usually be the same check every time (usually, not always, because shooting an adjacent Fire Demon without moving (double igui) is still allowed).

Right now I am supressing the new Highlight function with the old one, since the current code in Suzumu Shogi's interactive diagram relies on the call from the Highlight function. Once the pass for cab locust captures is implemented, I should be able to use the new function without any problems.


A. M. DeWitt wrote on Tue, Jan 24, 2023 11:43 AM EST in reply to H. G. Muller from 07:12 AM:

The extensive testing you do in BadZone() slows things down enormously. It is questionable whether this variant can ever be played by the Diagram's AI, (it outlasted my patience even at 2 ply), but this extra processing certainly doesn't help. If you need this amount of programming to make it work, it might be simpler to just replace some functions of the original script by slightly modified ones of your own. JavaScript allows you to redefine a function.

The amount of testing required for the Fire Demon was mainly because of the branching cases. With the new version, not only was I able to use the code from your comment to make the check much shorter, I was even able to remove three of the supporting functions because of this. As for code in general, sure, it will slow things down a lot, but that is to be expected from a complex game like Suzumu Shogi. You could treat it like a correspondence game in GC, though, so I was never too worried about it being too slow. I could probably do some optimization (I've saved this comment in my favorites), but right now I am just happy that everything is working properly.


A. M. DeWitt wrote on Tue, Jan 24, 2023 10:24 PM EST:

OK, I think I fixed it. The Betza compiler now refrains from inserting these 'loop directives' in the legs sequence when the NewClick move-entry method is used. I had to change some tests in the assignment of click sequences (which already relied on the presence of these directives) too. Distant or sliding rifle captures do not require the click to the final destination. This might be a folly, though, as it causes ambiguity when both the rifle and normal capture are allowed on the piece. Perhaps I should make this subject to a Diagram parameter autoComplete, and in general require all clicks, but consider the move entered when there is only one matching move left in the list, and at least two clicks have been given.

I am not even sure that swapping the order of locust victim and destination is always harmless, or whether it could lead to ambiguities too.

There does seem to be a problem when using the Lion Dog (XBetza: KADGHcavKabKmpafcavKcafcmpavK) with the newClick generation. When doing a double capture of the first two pieces in a straight line, and you click the second piece again, it always selects the two out one in option. This is probably due to the ambiguity caused when rifle captures and normal captures are allowed. I am planning on reviving Hook Shogi, and I intend to include the Lion Dog in it, so any help would be greatly appreciated.

I think the best solution would be some directive specifically for this kind of ambiguity, or to only skip a locust victim after cab if that locust victim's square is the only one that can be visited, so as to not destroy the directives that allow the Suzumu Fire Demon's burning restriction to work properly.


A. M. DeWitt wrote on Thu, Jan 26, 2023 07:25 PM EST in reply to H. G. Muller from 04:45 PM:

Thanks for fixing that. To be honest, I was a bit worried that the Suzumu Fire Demon might get messed up, but it turns out I was overreacting. And now that the Lion Dog works properly as well, I can include it and the Suzumu Fire Demon in the same game without needing to use any special code (apart from BadZone for the burning restriction, of course).

As for the paralyze parameter, I'm not sure whether it would actually increase efficiency or not. If paralyze doesn't suspend the BadZone call after move generation you would end up calling it twice instead of once, so it could slow things down even more if I am not careful with it. So for now, I am just going to keep Suzumu Shogi's BadZone code as it is.

I did encounter another minor bug. The highlights for the ShowMoves() function seem to be a bit bugged when using the new move generation. For example, when showing the possible moves of a piece after clicking its name, the Suzumu Fire Demon doesn't show the burn for its ranging moves, and hook moving pieces only show the hook moves for the first square in each direction. It appears to only be affecting atom such as R, B, and Q. It doesn't affect the diagram when clicking pieces on the actual board, but it can be a bit misleading. Thankfully, this shouldn't be too difficult to fix.


New Submissions for Review. A listing of all submissions still awaiting editorial approval.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Thu, Jan 26, 2023 08:44 PM EST in reply to Fergus Duniho from Sat Apr 16 2022 05:36 PM EDT:

What if you sorted based on the timestamp of the last action taken for each article? That way you don't have to worry about unset modification dates, and you can see which articles have changes ready for review.


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Fri, Jan 27, 2023 02:59 PM EST in reply to H. G. Muller from 11:13 AM:

I now also made promotion to empty square ('kamikaze capture') possible; it can be specified in the captureMatrix by a 0 (zero), and requested from the WeirdPromotion() custom script by returning 251 for the promotion piece. This means that it would now also be possible to implement the passive burning ability of a Tenjiku Shogi Fire Demon, by detecting in WeirdPromotion() whether a move lands next to an enemy Demon, and return 251 in that case.

Now all that is needed to successfully implement a interactive diagram for Tenjiku Shogi is to give WeirdPromotion the ability to affect other squares.

Edit: I tested this in an interactive diagram of Tenjiku Shogi, and the piece does get removed, but the diagram still thinks there is a piece there.


A. M. DeWitt wrote on Fri, Jan 27, 2023 08:35 PM EST in reply to H. G. Muller from 04:13 PM:

Speaking of XBetza (or rather, IBetza), you should really consider adding a link to your page on Extended Betza Notation to this page. Even if it is not strictly identical to the one used in the interactive diagrams it would be a very helpful edition. I did check for a link to that page before writing this, and I couldn't find one.

The new definition for t could be quite interesting. It also helps that kc covers the old function of t (excluding capture of royals).


A. M. DeWitt wrote on Sat, Jan 28, 2023 09:49 AM EST in reply to H. G. Muller from 08:26 AM:

Sounds awesome. Only problem is that returning 512 for the promomtion it doesn't work like it should. Instead of burning adjacent pieces it simply burns the moving piece as if you returned 251 for the promotion.


A. M. DeWitt wrote on Sat, Jan 28, 2023 11:06 AM EST in reply to H. G. Muller from 10:52 AM:

It works now.


Tenjiku Shogi. Fire Demons burn surrounding enemies, Generals capture jumping many pieces. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sat, Jan 28, 2023 04:36 PM EST in reply to H. G. Muller from 04:21 PM:

I also experienced this bug with contagious promotions. It seems the shogi promotion prompt is suppressing the WeirdPromotion result.


Variants playable against the diagram's AI. (Updated!) Index of variants that can be played against the interactive diagram.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Thu, Feb 2, 2023 07:42 PM EST:

Mitsugumi Shogi seems to be missing. It doesn't have as many problem pieces as its big brother Suzumu Shogi, so it can be added to the list without much trouble. I've also successfully tested a modified NextLeg function, which relieves the AI from having to use cumbersome recursive functions to vet moves for the range capturing pieces, which I will implement in the CVP articles soon.


Home page of The Chess Variant Pages. Homepage of The Chess Variant Pages.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Thu, Feb 2, 2023 10:29 PM EST:

The Review New Submissions page seems to be skewed towards new submissions now, rather than submissions that have new changes ready for review. This makes approving pages much harder, as you will only see the newest pages rather than the ones that have changes ready for review. Perhaps if the page is sorted by the timestamp of the last action taken on each article this can be rectified without having to worry about the unreliable modification date.

update test


Suzumu Shogi. 16x16 variant based on Tenjiku Shogi. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Fri, Feb 3, 2023 05:08 PM EST:

Suzumu Shogi is ready


Home page of The Chess Variant Pages. Homepage of The Chess Variant Pages.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Fri, Feb 3, 2023 07:34 PM EST:

Also, I am getting this error whenever I try to update my previous comment:

Attempting to update comment.

SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'WHERE `CommentID` = ?' at line 1

Update of Comment with ID of 46749 failed.


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sun, Feb 5, 2023 10:46 AM EST:

There is something wrong with the diagram for Desert Pub Chess. When the AI moves, it seems to spuriously remove pieces from the board in unpredictable ways. Furthermore, this bug also affects the desert pieces, causing them to not capture properly when they capture more than once.

Normal Move Bug Replication

Move each pawn forward one at a time, you should see the opponent's pawns add locust squares (the dull red highlights) when moving. Eventually the AI will make a Knight move that removes a friendly pawn. 

Desert Piece Bug

Make the following moves manually:

1. e2e4 f2g4 2. Fc8d5

Then open the AI dashboard and move a white piece. You will see some very strange behavior (only one white pawn gets captured and the other is "moved" to a different square).


Variants playable against the diagram's AI. (Updated!) Index of variants that can be played against the interactive diagram.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Sun, Feb 5, 2023 12:04 PM EST:

(Same as old page, but with the hyphen removed)


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Feb 7, 2023 10:37 AM EST:

Does trackPieces=N track the pieces around pieces of type N if spell is not set?


A. M. DeWitt wrote on Tue, Feb 7, 2023 09:54 PM EST in reply to H. G. Muller from 12:38 PM:

That's a really nice feature. For example, it saves a huge amount of time in the diagrams for Suzumu Shogi and Mitsugumi Shogi from not having to check nearly as many locations for Heavenly Tetrarches (which which immobilize non-Tetrarch pieces) during move vetting. I've now implemented the new code in the Rules pages for these games.

Also, can you approve the Rules pages for Suzumu Shogi and Mitsugumi Shogi? I've been waiting rather patiently, and their corresponding GC Preset pages have been approved, but the editors haven't seemed to notice the Rules pages, possibly due to the new sorting method for the Review New Submissions page.


A. M. DeWitt wrote on Wed, Feb 8, 2023 12:56 PM EST in reply to H. G. Muller from 03:03 AM:

I don't know how to approve articles; I limit my activities as editor to inserting Interactive Diagrams in existing articles, and improving the infra-structure for doing this. I am the only editor working on this task, and it doesn't seem a good idea to reduce the time I can spend on it by also taking up tasks that other editors can do.

That's OK. I assume you passed that along to another editor, and they approved it themselves.


A. M. DeWitt wrote on Wed, Feb 8, 2023 10:53 PM EST in reply to H. G. Muller from 02:21 PM:

It would be a misconception to think editors communicate amongst each other by any other means than the comments you can read here...

Well, whatever the case, the issue is settled. I'll let you get back to working on the Interactive Diagram code.


A. M. DeWitt wrote on Thu, Feb 9, 2023 02:46 PM EST in reply to H. G. Muller from 04:07 AM:

BTW, the tracking, and thus the marking the spell zone of the indicated piece, currently only works correctly if there are not more than two pieces of that type in play. Otherwise it will loose track of some of the pieces. The current way I use for tracking just keeps two locations (in loc[coloredType] and loc[coloredType+512]), of the last two pieces of that type that were moved during the search. (And it then only marks the spell zones around those.) Now this is fine for Mitsugumu Shogi, but in Suzumu Shogi there can potentially be 4 Tetrarchs. This is of course unlikely to happen in a real game, so perhaps we should not worry about it at all.

I can switch to a more robust way of tracking, able of handling an arbitrary number of pieces of the same type. This would cause a slight slowdown, though. Which is a pity, as almost no game would use it. An cheaper alternative would be to allow requesting spell zones around more than one piece type, so that piece types of which there can be more than two instances can be artificially split into two identical types. The location of each piece is tracked anyway, it is just a matter of marking the squares around the designated types before every move generation, and pieces where only a single type cause spells would not experience a delay by this.

It would even be possible to mark the spell zones of different types differently, e.g. as nodes | (1<<(24+K)) for the Kth spell zone. This would allow, say, freezing and burning in the same Diagram. The test for being in the zone would than have to be (neighbors[sqrNr] & 0xFFFFFF) == nodes. I wonder if all that complexity would be worth it, though. I am not even aware of any variants that would need it.

You could increase the cap of instances of one type for trackPieces to four without much trouble. This would take care of the 3+ Tetrarches problem in Suzumu Shogi while leaving plenty of room to handle the vast majority of cases. However, the more robust tracking method would be preferred for games using Chess-style promotion (you could have up to (#startingSpellPieces)+(#piecesPromotableToSpellPieces) pieces with spell effects).

As for multiple spells, I agree would not worry about that right now, as I can't see any variants that will be using that either. Besides, there is also the frozen variable, the 251 kamikaze promotion, and the 512(+[bits]) promotion methods, which can be used to implement spells in the xxZone, xxxPromotion, and xxxTinker scripts withouts using the spell parameters.

@Adam: I see that you are using your own markers. Beware that I have added a new marker (markerFFF000.png), which the betzaNew.js script uses for indicating moves of a piece that has active burning defined for it through the captureMatrix in the move diagrams. It then also indicates the blastZone on hovering, by making the background of the burned squares around the indicated target grey.

Thankfully that's very easy to do, as my markers are all simple circles.


A. M. DeWitt wrote on Sun, Feb 12, 2023 11:17 AM EST:

Would it be possible to implement a system to allow the inclusion of pieces with multiple-character IDs in the Diagram parameters that use them? If you need suggestions for how to implement something like this, Fergus uses a system in his FEN parser for Game Courier that surrounds multi-character piece IDs in {} curly brackets (e.g. {+P} for promoted Shogi pawn).

P.S. Those empty comments were me trying to insert this comment while I was not logged in, which may be the result of a bug.


A. M. DeWitt wrote on Mon, Feb 13, 2023 11:34 PM EST in reply to H. G. Muller from Sun Feb 12 04:17 PM:

I guess I don't really need the curly bracket enclosures.

However, I do need help with captureMatrix. I'm trying to use it to replace the modified NextLeg Function in Suzumu Shogi and Mitsugumi Shogi, and it works, but it seems to exclude certain cases where hops should be allowed (such as hopping over a lower-ranking friendly piece). Strangely, Minjiku Shogi does not have this problem. The captureMatrix value I have so far is this:

captureMatrix=//////////////////////////27^27,27^60,27^28,27^61,27^34,27^64,27^35,27^65,27^37,27^46/28^27,28^60,28^28,28^61,28^34,28^64,28^35,28^65,28^37,28^46//////34^34,34^64,34^35,34^65,34^37,34^46/35^35,35^65,35^37,35^46/////////////////////////60^27,60^60,60^28,60^61,60^34,60^64,60^35,60^65,60^37,60^46/61^27,61^60,61^28,61^61,61^34,61^64,61^35,61^65,61^37,61^46/././64^34,64^64,64^35,64^65,64^37,64^46/65^35,65^65,65^37,65^46
 


chessshogi wrote on Tue, Feb 14, 2023 01:44 PM EST in reply to H. G. Muller from 03:06 AM:

Now I've got it figured out. Thanks to this, I no longer need the modified NextLeg function (jumpClass is still needed to for the multi-captures though).


A. M. DeWitt wrote on Tue, Feb 14, 2023 02:05 PM EST in reply to H. G. Muller from 03:06 AM:

Now I have it figured out. Thanks. I'll also redo the Tenjiku Diagram so it uses captureMatrix instead.


Tenjiku Shogi. Fire Demons burn surrounding enemies, Generals capture jumping many pieces. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Feb 14, 2023 04:07 PM EST:

Here's an Interactive Diagram for Tenjiku Shogi (following Wikipedia/CVP ruleset).

satellite=wikipedia files=16 ranks=16 holdingsType=0 promoOffset=35 promoZone=5 maxPromote=30 promoChoice=+ royal=35 royal=44 captureMatrix=/"25/.27^^.4^3.8^.13^^..^^=/"//"3/.33^3.8^.17^^=/.34^^.8^.18^=//"22/.27^^.4^3.8^.13^^..^^=/"///.33^3.8^.17^^=/.34^^.8^.18^=//@66/" stalemate=win graphicsDir=https://www.chessvariants.com/graphics.dir/tenjikushogi/ whitePrefix= blackPrefix=flip/ lightShade=#FFFF80 darkShade=#FFFF80 graphicsType=gif squareSize=36 symmetry=rotate firstRank=1 rimColor=#000000 coordColor=#FFFFFF newClick=1 trackPieces=65 trackedTypes=2 spell=burn spellZone=K blastZone=K atomicCapture=0 pawn:P:fW:Pawn:a5-p5 dog:D:bFfW:Dog:e6,l6 iron general:I:fFfW:IronGeneral:d1,m1 copper general:C:fFvW:CopperGeneral:e1,l1 silver general:S:FfW:SilverGeneral:f1,k1 ferocious leopard:FL:FvW:FerociousLeopard:c1,n1 gold general:G:WfF:GoldGeneral:g1,j1 blind tiger:BT:FsbW:BlindTiger:f2,k2 drunk elephant:DE:FsfW:DrunkenElephant:i1 knight:N:fN:Knight:b1,o1 kirin:KY:FD:Kyrin:g2 phoenix:PH:WA:Phoenix:j2 lance:L:fR:Lance:a1,p1 reverse chariot:RV:vR:ReverseChariot:a2,p2 side mover:SM:vWsR:SideMover:a4,p4 vertical mover:VM:sWvR:VerticalMover:b4,o4 side soldier:SS:bWsRfW2:SideSoldier:a3,p3 vertical soldier:VS:bWfRsW2:VerticalSoldier:b3,o3 bishop:B:B:Bishop:c3,n3 rook:R:R:Rook:c4,n4 dragon horse:DH:BW:DragonHorse:d3,m3 dragon king:DK:RF:DragonKing:e3,l3 horned falcon:HF:BsbRfWfDfcavWfabW:HornedFalcon:d4,m4 soaring eagle:SE:RbBfFfAfcavFfabF:SoaringEagle:e4,l4 lion:LN:KNADcaKmcabK:Lion:h2 queen:Q:Q:FreeKing:i2 bishop general:BG:B(paf)0kcB:BishopGeneral:f4,k4 rook general:RG:R(paf)0kcR:RookGeneral:g4,j4 chariot soldier:CS:BvRsW2:ChariotSoldier:c2,d2,m2,n2 water buffalo:WB:BsRvW2:WaterBuffalo:f3,k3 free eagle:FE:QADcaFmcabF:FreeEagle:i3 lion hawk:LH:BWNADcaKmcabK:LionHawk:h3 vice general:VG:B(paf)0kcB(a)2KabK:ViceGeneral:i4 great general:GG:Q(paf)0kcQ:GreatGeneral:h4 value=3500 king:K:K:King:h1 tokin:+P:WfF:PawnP: multi general:+D:bBfR:DogP: vertical soldier:+I:bWfRsW2:IronGeneralP: side mover:+C:vWsR:CopperGeneralP: vertical mover:+S:sWvR:SilverGeneralP: bishop:+FL:B:FerociousLeopardP: rook:+G:R:GoldGeneralP: flying stag:+BT:FsWvR:BlindTigerP: prince:+DE:K:DrunkenElephantP: side soldier:+N:bWsRfW2:KnightP: lion:+KY:KNADcaKmcabK:KyrinP: queen:+PH:Q:PhoenixP: white horse:+L:fBvR:Lance: whale:+RV:bBvR:ReverseChariotP: free boar:+SM:BsR:SideMoverP: flying ox:+VM:BvR:VerticalMoverP: water buffalo:+SS:BsRvW2:SideSoldierP: chariot soldier:+VS:BvRsW2:VerticalSoldierP: dragon horse:+B:BW:BishopP: dragon king:+R:RF:RookP: horned falcon:+DH:BsbRfWfDfcavWfabW:DragonHorseP: soaring eagle:+DK:RbBfFfAfcavFfabF:DragonKingP: bishop general:+HF:B(paf)0kcB:HornedFalconP: rook general:+SE:R(paf)0kcR:SoaringEagleP: lion hawk:+LN:BWNADcaKmcabK:LionP: free eagle:+Q:QADcaFmcabF:FreeKingP: vice general:+BG:B(paf)0kcB(a)2KabK:BishopGeneralP: great general:+RG:Q(paf)0kcQ:RookGeneralP: value=3500 heavenly tetrarch:+CS:jvhQjsQ3cabK:ChariotSoldierP: fire demon:+WB:shQ(a)2KabK:WaterBuffaloP: fire demon:FD:shQ(a)2KabK:FireDemon:g3,j3

Mitsugumi Shogi. Smaller variant of Suzumu Shogi on a 13x13 board. (13x13, Cells: 169) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Tue, Feb 14, 2023 04:32 PM EST in reply to Fergus Duniho from 03:36 PM:

The 404 script is logging many 404 errors from this page for graphic images.

The paths from the errors are the paths used in the diagrams on my computer. I already fixed that.


Interactive diagrams. Diagrams that interactively show piece moves.[All Comments] [Add Comment or Rating]
A. M. DeWitt wrote on Tue, Feb 14, 2023 04:50 PM EST in reply to H. G. Muller from 03:06 AM:

Speaking of captureMatrix, I updated the Tenjiku Shogi Interactive Diagram to use it, and I noticed that the burn marker was only being used on the last piece that had burning abilities from captureMatrix. You can see it in action by clicking the link and promoting a Water Buffalo and clicking the newly gained Fire Demon, and then compare it to one of the original Fire Demons.


Hook Shogi. 16x16 variant with the hook movers from the largest Shogi variants. (16x16, Cells: 256) [All Comments] [Add Comment or Rating]
💡📝A. M. DeWitt wrote on Wed, Feb 15, 2023 09:48 PM EST in reply to Fergus Duniho from Tue Feb 14 05:31 PM:

The 404 script has logged a bunch of 404 errors from this page for graphic images.

Thanks for letting me know, but reporting it isn't necessary. When the errors pops up, I immediately notice that the interactive diagram on the page is blank (the path used is the one for the interactive diagrams on my personal computer) and fix the error.


100 comments displayed

EarliestEarlier Reverse Order LaterLatest

Permalink to the exact comments currently displayed.