Skip to content

Commit 0da1e29

Browse files
committed
Release candidate
1 parent fb0d24f commit 0da1e29

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ You can implement your own transposition table and its policy (which positions t
1414
It also provides you with other useful building blocks like a clock, PerfT tests (for testing your move generator), or abstract implementations of move library (typically openings book for chess).
1515

1616
# Known limitations
17-
- The AI always supposes a player that can't move loosed or make a draw ... which is not always the case (typically in [Reversi](https://en.wikipedia.org/wiki/Reversi)).
17+
- The AI always supposes that when a player can't move the game is ended ... which is not always the case (typically in [Reversi](https://en.wikipedia.org/wiki/Reversi)).
1818
This doesn't means that the AI can't be used to play Reversi. Simply, the reversi move generator should have a special '*can't play*' move returned when a player can't move but the game is not finished.
1919
- The Negamax is quite basic, it implements a highly configurable transposition and quiesce move search, but none other advanced algorithm (no PV search, futility pruning, killer or null move, etc ...).
2020

@@ -29,4 +29,4 @@ As it seems, in real life, a new context is created at each AI invocation, a bet
2929
- There's a strange behavior with transposition table. There's some situations where a never replace strategy leads to a faster resolution. It is totally counter intuitive.
3030
- MoveGenerator:
3131
- It would be more efficient to have the moveGenerator generating directly an iterator of moves instead of a list of moves. It would allow to use incremental move generators that starts by returning, what can hope to be the best moves (for instance captures), and other moves if these first moves are consumed. Indeed, in alpha/beta ai, the first moves are often enough to trigger a cut, so generating all the moves is a waste of time.
32-
- Write more tests and Documentation ;-)
32+
- Write more tests ;-)

src/main/java/com/fathzer/games/ai/AbstractAI.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -123,13 +123,12 @@ public void interrupt() {
123123
* @param status The status of the game
124124
* @param depth The current search depth
125125
* @param maxDepth The maximum depth of the search
126-
* @return The score. The default implementation returns 0 for a draw, and calls {@link Evaluator#getWinScore(int)} for a loss.
126+
* @return The score. The default implementation returns 0 for a draw, otherwise it considers the player loose and returns -{@link Evaluator#getWinScore(int)}.
127127
*/
128128
protected int getScore(final Evaluator<M,B> evaluator, final Status status, final int depth, int maxDepth) {
129129
if (Status.DRAW==status) {
130130
return 0;
131131
} else {
132-
//FIXME Maybe there's some games where the player wins if it can't move...
133132
return -evaluator.getWinScore(maxDepth-depth);
134133
}
135134
}

0 commit comments

Comments
 (0)