Check out Janggi (Korean Chess), our featured variant for December, 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 ]

Single Comment

ChessBreakTimes Chess. Chess with elements of chess-based RPG I slowly elaborate at this time. (8x8, Cells: 64) [All Comments] [Add Comment or Rating]
H. G. Muller wrote on Sat, Aug 26, 2023 08:22 PM UTC in reply to Diceroller is Fire from 06:53 PM:

Still same result(

Well, it seems you have been messing up the legdefs array, swapping piece definitions, as the numbers returned by the piece functions no longer correspond to the move definitions for the corresponding piece. In some cases they are even 'out of phase', so that the y-step of a piece is interpreted as a range, and this causes the error when the y-step is too negative.

For example, you have

def N cond #0 135 0;

But in fact the legdefs array contains the definition of Silver in that location, not Knight. You apparently have inserted the Silver definitions before that of Knight, with as a result that the definition of the Knight moves now starts at 187 instead of 135. You cannot juggle the move definitions in legdefs without adapting the piece routines to the new location of their moves.