mirror of
https://github.com/sockspls/badfish
synced 2025-04-30 00:33:09 +00:00
Revert opponent time advantage logic
Strength increase was due to an hidden bug introduced by the patch, namely the time per move to /30 instead of /40 (see previous patch). After testing this feature do not add any substantial increase so is removed. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
parent
9d5d69e435
commit
d95b9189d8
1 changed files with 1 additions and 7 deletions
|
@ -188,7 +188,7 @@ namespace {
|
|||
// Time managment variables
|
||||
int SearchStartTime;
|
||||
int MaxNodes, MaxDepth;
|
||||
int MaxSearchTime, AbsoluteMaxSearchTime, ExtraSearchTime, TimeAdvantage;
|
||||
int MaxSearchTime, AbsoluteMaxSearchTime, ExtraSearchTime;
|
||||
Move BestRootMove, PonderMove, EasyMove;
|
||||
int RootMoveNumber;
|
||||
bool InfiniteSearch;
|
||||
|
@ -427,8 +427,6 @@ void think(const Position &pos, bool infinite, bool ponder, int side_to_move,
|
|||
int myIncrement = increment[side_to_move];
|
||||
int oppTime = time[1 - side_to_move];
|
||||
|
||||
TimeAdvantage = myTime - oppTime;
|
||||
|
||||
if (!movesToGo) // Sudden death time control
|
||||
{
|
||||
if (myIncrement)
|
||||
|
@ -680,10 +678,6 @@ namespace {
|
|||
ExtraSearchTime = BestMoveChangesByIteration[Iteration] * (MaxSearchTime / 2)
|
||||
+ BestMoveChangesByIteration[Iteration-1] * (MaxSearchTime / 3);
|
||||
|
||||
// If we need some more and we are in time advantage take it
|
||||
if (ExtraSearchTime > 0 && TimeAdvantage > 2 * MaxSearchTime)
|
||||
ExtraSearchTime += MaxSearchTime / 2;
|
||||
|
||||
// Try to guess if the current iteration is the last one or the last two
|
||||
LastIterations = (current_search_time() > ((MaxSearchTime + ExtraSearchTime)*58) / 128);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue