A third thing if I may ask in these game the king may castle in 2 ways with the rook that starts near the corner of the board or with the corner cannon. Omega chess implements a castle move with a non corner piece. Can I combine this with the regular castling subroutine in order to easily make my castle subroutine work?
What castling rule do you want it to work for?