aboutsummaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp44
1 files changed, 2 insertions, 42 deletions
diff --git a/src/main.cpp b/src/main.cpp
index ddeb304..8a1821e 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -1,52 +1,12 @@
-#include "board.hpp"
-#include "fen.hpp"
-#include "moves.hpp"
#include "uci.hpp"
#include "zobrist.hpp"
-#include <cstdio>
+
#include <cstdlib>
#include <ctime>
-#include <string>
-
-using namespace std;
-
-enum Mode {
- EXIT,
- REPL,
-};
-
-void setAllPiecesToEmpty(Game *b) {
- Piece EmptyPiece = {
- false,
- NONE,
- false,
- };
- for (int i = 0; i < 64; i++) {
- b->pieces[i] = EmptyPiece;
- };
-};
-Game initBoard(string startingFEN) {
- Game b;
- b.enPassant = IndexToPosition(0); // default value
- b.canEnpassant = false;
- b.state = TURN;
- b.turn = true;
- b.castle = "";
- b.halfMoveClock = 0;
- b.MoveClock = 0;
- setBoardFen(startingFEN, &b);
- return b;
-};
-int main(int argc, char **argv) {
+int main() {
InitZobrist();
srand(time(0));
- if (argc < 1 || argc > 2) {
- printf("wrong arg count, use: ./chess [--repl for debugging]\n");
- return 1;
- }
- if (argc > 1 && std::string(argv[1]) == "--repl")
- return startREPL();
Uci();
return 0;