Changing license to GPL3 (and bumping version to 1.4.0).
[gnushogi.git] / gnushogi / book.h
1 /*
2  * FILE: book.h
3  *
4  * ----------------------------------------------------------------------
5  *
6  * Copyright (c) 2012 Free Software Foundation
7  *
8  * GNU SHOGI is based on GNU CHESS
9  *
10  * This file is part of GNU SHOGI.
11  *
12  * GNU Shogi is free software; you can redistribute it and/or modify it
13  * under the terms of the GNU General Public License as published by the
14  * Free Software Foundation; either version 3 of the License,
15  * or (at your option) any later version.
16  *
17  * GNU Shogi is distributed in the hope that it will be useful, but WITHOUT
18  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
19  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
20  * for more details.
21  *
22  * You should have received a copy of the GNU General Public License along
23  * with GNU Shogi; see the file COPYING. If not, see
24  * <http://www.gnu.org/licenses/>.
25  * ----------------------------------------------------------------------
26  *
27  */
28
29 #ifndef _BOOK_H_
30 #define _BOOK_H_
31
32 struct gdxadmin
33 {
34     ULONG bookcount;
35     ULONG booksize;
36     ULONG maxoffset;
37 };
38
39 extern struct gdxadmin B;
40
41
42 #define GOODMOVE 0x1000
43 #define BADMOVE  0x0100
44 #define LASTMOVE 0x0010
45
46 struct gdxdata
47 {
48     ULONG  hashbd;
49     USHORT hashkey;
50     USHORT bmove;
51     USHORT flags; /* flags BADMOVE, GOODMOVE,  LASTMOVE */
52     USHORT hint;
53     USHORT count;
54 };
55
56
57 #define sizeof_gdxadmin sizeof(struct gdxadmin)
58 #define sizeof_gdxdata  sizeof(struct gdxdata)
59
60 #endif /* _BOOK_H_ */
61