movegen: refactor: 函数重命名
This commit is contained in:
parent
f8bae1b167
commit
92c65f3c2d
|
@ -297,7 +297,7 @@ void MoveList::shuffle()
|
|||
/// generate<LEGAL> generates all the legal moves in the given position
|
||||
|
||||
//template<>
|
||||
ExtMove *generate(/* TODO: const */ Position *position, ExtMove *moveList)
|
||||
ExtMove *generateMoves(/* TODO: const */ Position *position, ExtMove *moveList)
|
||||
{
|
||||
square_t square;
|
||||
player_t opponent;
|
||||
|
|
|
@ -61,7 +61,7 @@ inline bool operator < (const ExtMove &first, const ExtMove &second)
|
|||
}
|
||||
|
||||
//template <GenType>
|
||||
ExtMove *generate(Position *pos, ExtMove *moveList);
|
||||
ExtMove *generateMoves(Position *pos, ExtMove *moveList);
|
||||
|
||||
/// The MoveList struct is a simple wrapper around generate(). It sometimes comes
|
||||
/// in handy to use this class instead of the low level generate() function.
|
||||
|
|
|
@ -469,7 +469,7 @@ value_t AIAlgorithm::search(depth_t depth, value_t alpha, value_t beta)
|
|||
|
||||
ExtMove extMoves[MAX_MOVES];
|
||||
memset(extMoves, 0, sizeof(extMoves));
|
||||
ExtMove *end = generate(st->position, extMoves);
|
||||
ExtMove *end = generateMoves(st->position, extMoves);
|
||||
MovePicker mp(st->position, extMoves);
|
||||
mp.score();
|
||||
|
||||
|
|
Loading…
Reference in New Issue