]> git.sesse.net Git - remoteglot/commitdiff
Another castling fix.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 7 Jan 2018 00:43:20 +0000 (01:43 +0100)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 7 Jan 2018 00:43:20 +0000 (01:43 +0100)
Position.pm

index cd0cc975ff5fad2e3ff176ec7da634d76f1002ab..93bde53d334670e64a114f9881545ae37be8f987 100644 (file)
@@ -84,7 +84,7 @@ sub from_fen {
                }
        }
        if ($castling =~ /k/) {
-               $pos->{'white_castle_k'} = _col_num_to_letter(_find_piece_col_from_right($board->[0], 'r'));
+               $pos->{'black_castle_k'} = _col_num_to_letter(_find_piece_col_from_right($board->[0], 'r'));
        }
        if ($castling =~ /q/) {
                $pos->{'black_castle_q'} = _col_num_to_letter(_find_piece_col($board->[0], 'r'));