we can now print a move (stockfish stile)
This commit is contained in:
parent
df07b4399d
commit
974af5d19f
@ -1,6 +1,7 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "castle_side.hpp"
|
#include "castle_side.hpp"
|
||||||
|
#include "coords.hpp"
|
||||||
#include "pieces/piece.hpp"
|
#include "pieces/piece.hpp"
|
||||||
|
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
@ -14,3 +15,9 @@ struct Move {
|
|||||||
bool en_passant = false;
|
bool en_passant = false;
|
||||||
int8_t promoting_to = Piece::None;
|
int8_t promoting_to = Piece::None;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
inline std::ostream& operator<<(std::ostream& os, const Move& m) {
|
||||||
|
os << Coords::from_index(m.source_square)
|
||||||
|
<< Coords::from_index(m.target_square);
|
||||||
|
return os;
|
||||||
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user