[ List Earliest Comments Only For Pages | Games | Rated Pages | Rated Games | Subjects of Discussion ]
Check out Janggi (Korean Chess), our featured variant for December, 2024.
Check out Janggi (Korean Chess), our featured variant for December, 2024.
This can be excluded. Moves for each piece are generated by NewInner, which then calls NextLeg (recursively for multi-leg moves), which finally calls StackMove (possibly a number of times if there are sliding legs). NewInner loops over the move-descriptors in the move table for the piece, and clears kind before every entry it passes to NextLeg. So the effect of altering kind could at most extend to all moves generated from the same move descriptor. Which is moves with longer sliding leg.
This was intentional: some bits in kind indicate whether you have passed over a square mutated by the previous two ply, in order to recognize discovered attacks and hopper activations. Lions do not have any sliding legs, though. So each move descriptor would only result in a single move.
If you post a Diagram for which it does not work, I can debug that.
[Edit] For hook movers (which have a sliding non-final leg) this is broken, as the sticky bits remain from one continuation to a different, non-overlapping continuation. The routine NextLeg should save the value of kind before calling itself recursively for the next leg, and restore it afterwards. I will make it do so.