nkarve / surge

A fast bitboard-based chess move generator in C++
MIT License
62 stars 15 forks source link

surge

A fast bitboard-based legal chess move generator, written in C++

Features:

perft(6) from starting position:

perft(6)

Getting Started:

#include "position.h"
#include "tables.h"
#include "types.h"

int main() {
    initialise_all_databases();
    zobrist::initialise_zobrist_keys();

    Position p;
    Position::set("rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq -", p);
    std::cout << p; 

    MoveList<WHITE> list(p)

    for(Move m : list) {
        std::cout << m << "\n";
    }

    return 0;
}