diff -ru hexxagon-1.0-orig/src/libhexx/bitboard64.h hexxagon-1.0/src/libhexx/bitboard64.h --- hexxagon-1.0-orig/src/libhexx/bitboard64.h 2005-01-13 13:19:07.000000000 -0800 +++ hexxagon-1.0/src/libhexx/bitboard64.h 2009-08-12 13:11:57.663180010 -0700 @@ -19,12 +19,12 @@ * */ - #ifndef _BITBOARD64_H #define _BITBOARD64_H #include #include +#include namespace libhexx { @@ -54,14 +54,12 @@ { printf("0x%X, 0x%X\n", lowbits, highbits); }; - - friend std::ostream& operator<<(std::ostream &output, const class BitBoard64 &b); - friend std::istream& operator>>(std::istream &input, class BitBoard64 &b); - - private: - + uint32_t lowbits, highbits; }; + + std::ostream& operator<<(std::ostream &output, const class BitBoard64 &b); + std::istream& operator>>(std::istream &input, class BitBoard64 &b); } #endif diff -ru hexxagon-1.0-orig/src/libhexx/board.h hexxagon-1.0/src/libhexx/board.h --- hexxagon-1.0-orig/src/libhexx/board.h 2005-01-16 03:12:23.000000000 -0800 +++ hexxagon-1.0/src/libhexx/board.h 2009-08-13 07:45:36.258630712 -0700 @@ -33,8 +33,24 @@ namespace libhexx { - class Move; - class MoveList; +#ifndef _MOVE_DEFINED +#define _MOVE_DEFINED + class Move + { + public: + Move(); + Move(int t); + Move(int f, int t); + + operator bool() const; + + char from, to; + int score; + }; + + bool scoreMoves(std::vector &moves, class Board board, + const LookUp& lookUp, int depth, bool (*callback)(), int maxtime); +#endif enum { diff -ru hexxagon-1.0-orig/src/libhexx/libhexx.h hexxagon-1.0/src/libhexx/libhexx.h --- hexxagon-1.0-orig/src/libhexx/libhexx.h 2005-01-13 13:19:07.000000000 -0800 +++ hexxagon-1.0/src/libhexx/libhexx.h 2009-08-13 07:49:35.222755311 -0700 @@ -19,11 +19,10 @@ * */ - #include "bitboard64.h" +#include "lookup.h" #include "move.h" #include "board.h" #include "game.h" -#include "lookup.h" #include "view.h" #include "layout.h" diff -ru hexxagon-1.0-orig/src/libhexx/lookup.h hexxagon-1.0/src/libhexx/lookup.h --- hexxagon-1.0-orig/src/libhexx/lookup.h 2005-01-13 13:19:07.000000000 -0800 +++ hexxagon-1.0/src/libhexx/lookup.h 2009-08-12 11:58:08.758180417 -0700 @@ -27,6 +27,8 @@ namespace libhexx { + class BitBoard64; + int getHexxagonIndex(int x, int y); class LookUp diff -ru hexxagon-1.0-orig/src/libhexx/move.cpp hexxagon-1.0/src/libhexx/move.cpp --- hexxagon-1.0-orig/src/libhexx/move.cpp 2005-01-16 03:12:23.000000000 -0800 +++ hexxagon-1.0/src/libhexx/move.cpp 2009-08-12 13:12:27.140180083 -0700 @@ -114,4 +114,11 @@ return true; } - +Move::Move() { from = 99; to = 99;}; +Move::Move(int t) { from = t; to = t; }; +Move::Move(int f, int t) { from = f; to = t; }; + +Move::operator bool() const +{ + return from != 99 && to != 99; +} diff -ru hexxagon-1.0-orig/src/libhexx/move.h hexxagon-1.0/src/libhexx/move.h --- hexxagon-1.0-orig/src/libhexx/move.h 2005-01-13 13:19:07.000000000 -0800 +++ hexxagon-1.0/src/libhexx/move.h 2009-08-13 07:45:45.073630224 -0700 @@ -23,19 +23,21 @@ #ifndef _MOVE_H #define _MOVE_H -#include "board.h" - #include #include namespace libhexx { + class Board; + +#ifndef _MOVE_DEFINED +#define _MOVE_DEFINED class Move { public: - Move() { from = 99; to = 99;}; - Move(int t) { from = t; to = t; }; - Move(int f, int t) { from = f; to = t; }; + Move(); + Move(int t); + Move(int f, int t); inline bool operator<(const Move &r) const { @@ -47,13 +49,14 @@ return (score != r.score); }; - operator bool() const { return from != 99 && to != 99; }; + operator bool() const; char from, to; int score; }; bool scoreMoves(std::vector &moves, class Board board, const LookUp& lookUp, int depth, bool (*callback)(), int maxtime); +#endif } //namespace libhexx #endif // _HEXXAGONMOVE_H