mirror of
https://github.com/sockspls/badfish
synced 2025-04-29 16:23:09 +00:00
Define OnePly as a Depth enum costant
There is no reason to use a variable for this. Also remove unused DEPTH_ZERO and DEPTH_MAX. No functional change. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
parent
cf4c28ff86
commit
cfb52fcd5d
2 changed files with 4 additions and 11 deletions
13
src/depth.h
13
src/depth.h
|
@ -26,19 +26,12 @@
|
||||||
////
|
////
|
||||||
|
|
||||||
enum Depth {
|
enum Depth {
|
||||||
DEPTH_ZERO = 0,
|
|
||||||
DEPTH_MAX = 200, // 100 * OnePly;
|
OnePly = 2,
|
||||||
DEPTH_NONE = -254 // -127 * OnePly
|
DEPTH_NONE = -127 * OnePly
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
////
|
|
||||||
//// Constants
|
|
||||||
////
|
|
||||||
|
|
||||||
const Depth OnePly = Depth(2);
|
|
||||||
|
|
||||||
|
|
||||||
////
|
////
|
||||||
//// Inline functions
|
//// Inline functions
|
||||||
////
|
////
|
||||||
|
|
|
@ -1897,7 +1897,7 @@ namespace {
|
||||||
&& pos.type_of_piece_on(move_to(m)) != PAWN
|
&& pos.type_of_piece_on(move_to(m)) != PAWN
|
||||||
&& pos.see_sign(m) >= 0)
|
&& pos.see_sign(m) >= 0)
|
||||||
{
|
{
|
||||||
result += OnePly/2;
|
result += OnePly / 2;
|
||||||
*dangerous = true;
|
*dangerous = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue