zobristTableGet
This commit is contained in:
@ -54,6 +54,7 @@ struct castle_t {
|
||||
struct gameState_t {
|
||||
uint_least64_t *board;
|
||||
uint_least64_t zobrist;
|
||||
uint_least8_t *repetitionTable;
|
||||
bool color; // color to move
|
||||
struct castle_t canCastle[2];
|
||||
|
||||
|
||||
@ -1,6 +1,23 @@
|
||||
#include <stdbool.h>
|
||||
#include <stddef.h>
|
||||
#include <stdint.h>
|
||||
#include <chess/types.h>
|
||||
|
||||
struct zobristTableElement {
|
||||
uint_least64_t hash;
|
||||
int_least16_t value;
|
||||
};
|
||||
|
||||
struct zobristTable {
|
||||
struct zobristTableElement *arr;
|
||||
size_t length;
|
||||
};
|
||||
|
||||
struct zobristTableResult {
|
||||
bool success;
|
||||
int_least16_t value;
|
||||
};
|
||||
|
||||
uint_least64_t rand_64();
|
||||
uint_least64_t zobristPieceI(struct piece_t piece, uint_least8_t field);
|
||||
uint_least8_t getFile(const uint_least8_t field);
|
||||
|
||||
Reference in New Issue
Block a user