what value to return at ply >=maxply ?

Discussion of chess software programming and technical issues.

Moderator: Ras

MahmoudUthman
Posts: 237
Joined: Sat Jan 17, 2015 11:54 pm

what value to return at ply >=maxply ?

Post by MahmoudUthman »

stockfish returns the evaluation value unless incheck it return a draw value , why is that ?
User avatar
cdani
Posts: 2204
Joined: Sat Jan 18, 2014 10:24 am
Location: Andorra

Re: what value to return at ply >=maxply ?

Post by cdani »

MahmoudUthman wrote:stockfish returns the evaluation value unless incheck it return a draw value , why is that ?
Evaluation due to the inability to go further, so the does the same done at the end of quiesce, and draw value for check due to inability to evaluate at all. For this second case also could had been used the static evaluation of the previous ply, just to return something. In any case the effect of this is 0.
User avatar
hgm
Posts: 28472
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: what value to return at ply >=maxply ?

Post by hgm »

It should not matter because it is not supposed to happen on a branch that makes sense.