Author: scott farrell
Date: 10:05:41 09/14/02
Go up one level in this thread
//////////////////////////////////////////////////////////////////////////////////////////////////////
// SET A TABLE ENTRY
//////////////////////////////////////////////////////////////////////////////////////////////////////
public final static void store(
int _depth,
int _value,
Move _best,
char _flag,
boolean _estOnly,
short _reqSE,
Board _b,
boolean usingSecondTE_notbeingused,
boolean _dontNullMove)
{
if (_estOnly)
return;
int key= 0;
long checkKeyt= 0;
if (_b.sideToMove == Board.BLACK)
{
key= ~_b.key & (size - 1);
checkKeyt= ~_b.checkKey;
} else
{
key= _b.key & (size - 1);
checkKeyt= _b.checkKey;
}
boolean collision=
checkKeyt != checkKey[key] && checkKey[key] != 0 && stale[key] == false;
if (stale[key]
|| (_depth > (int) depth[key])
|| (_depth == (int) depth[key] && _flag > flag[key]))
{
depth[key]= _depth;
value[key]= _value;
flag[key]= _flag;
SERequired[key]= _reqSE;
stale[key]= false;
checkKey[key]= checkKeyt;
dontNullMove[key]= _dontNullMove;
if (_best != null)
{
if (s1[key] != _best.s1
|| s2[key] != _best.s2) // its a different move or empty
{
s1[key]= (byte) _best.s1;
s2[key]= (byte) _best.s2;
}
} // end if replace
else
{
// store2nd(_depth, _value, _best, _flag, _reqSE, _b,
_dontNullMove);
}
}
This page took 0 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.