Chess Game  1.1.0
A full chess game for Unity
cgValueModifiers Class Reference

The following values dictate the playing and searching style of the engine greatly. More...

Public Attributes

const int Value_Pawn = 1000
 The value of a pawn, used by the engine to evalute board states. More...
 
const int Value_Rook = 5000
 The value of a rook, used by the engine to evalute board states. More...
 
const int Value_Knight = 3000
 The value of a knight, used by the engine to evalute board states. More...
 
const int Value_Bishop = 3150
 The value of a bishop, used by the engine to evalute board states. There seems to be a general consensus that the bishop, especially in the lategame, is slightly better than the knight. More...
 
const int Value_Queen = 9000
 The value of a queen, used by the engine to evalute board states. More...
 
const int Value_King = 50000
 The value of a king, used by the engine to evalute board states. This value should always be arbitrarily high. More...
 
const short Value_CastlingShortRights = 22
 How much the right to castle short is valued at. More...
 
const short Value_CastlingLongRights = 15
 How much the right to castle long is valued at More...
 
const sbyte Value_Castle = 85
 How much having castled is valued at. More...
 
const int Value_BishopPairBonus = 200
 A bonus value given for having both bishops. Leading the AI to be less likely to exchange say a bishop for a knight. More...
 
const int Value_RookPairBonus = 200
 A bonus value for having both rooks. Leading the AI to be less likely to exchange a rook for say a bishop + 2 pawns, which is valued at 5 same as the rook. More...
 
const sbyte AlphaBeta_Weight_Capture = sbyte.MaxValue
 
const sbyte AlphaBeta_Weight_LongCastle = 30
 
const sbyte AlphaBeta_Weight_ShortCastle = 30
 
const sbyte AlphaBeta_Weight_Check = 50
 
const sbyte AlphaBeta_Strong_Delineation = 20
 

Static Public Attributes

static sbyte [] Positions_Bishop
 The positional value of the bishop on each square. Notice the high value for a7 a2 g7 and g2, this means fianchettos are valued high. More...
 
static sbyte [] Positions_Rook
 The positional value of the rook on each square. More...
 
static sbyte [] Positions_Knight
 The positional value of the knight on each square. Note: the knight is great in the center. More...
 
static sbyte [] Positions_Pawn
 The positional value of the pawn on each square. Note: a strong pawn center is valued high. More...
 
static sbyte [] Positions_Queen
 The positional value of the queen on each square. More...
 

Detailed Description

The following values dictate the playing and searching style of the engine greatly.

Member Data Documentation

◆ Positions_Bishop

sbyte [] cgValueModifiers.Positions_Bishop
static
Initial value:
=
{
-20,0, 0, 0, 0, 0, 0, -20,
0, 22, 5, 5, 5, 5, 22, 0,
10, 0, 12, 15, 15, 12, 5, 10,
5, 10, 12, 25, 25, 12, 10, 5,
5, 10, 12, 25, 25, 12, 10, 5,
10, 5, 12, 12, 15, 12, 5, 10,
0, 22, 5 , 5, 5, 5, 22, 0,
-20,0, 0, -10, 0, -10, 0, -20}

The positional value of the bishop on each square. Notice the high value for a7 a2 g7 and g2, this means fianchettos are valued high.

◆ Positions_Knight

sbyte [] cgValueModifiers.Positions_Knight
static
Initial value:
=
{
0, -5, 0, 0, 0, 0, -5, 0,
0, 0, 0, 5, 5, 0, 0, 0,
3, 5, 25, 25, 25, 25, 5, 3,
0, 15, 25, 40, 40, 25, 15, 0,
0, 15, 25, 40, 40, 25, 15, 0,
3, 5, 25, 25, 25, 25, 5, 3,
0, 0, 0, 5, 5, 0, 0, 0,
0, -5, 0, 0, 0, 0, -5, 0}

The positional value of the knight on each square. Note: the knight is great in the center.

◆ Positions_Pawn

sbyte [] cgValueModifiers.Positions_Pawn
static
Initial value:
=
{
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
3, 3, 5, 5, 5, 5, 3, 3,
-10, 3, 12, 15, 23, 12, 5, -10,
-10, 0, 15, 15, 22, 12, 7, -10,
5, 5, 15, 15, 15, 15, 5, 5,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0}

The positional value of the pawn on each square. Note: a strong pawn center is valued high.

◆ Positions_Queen

sbyte [] cgValueModifiers.Positions_Queen
static
Initial value:
=
{
0, 0, 0, 0, 1, 0, 0, 0,
0, 2, 15, 0, 6, 0, 0, 0,
3, 5, 0, 5, 5, 5, 3, 3,
12, 0, 0, 0, 0, 0, 0, 15,
0, 0, 0, 0, 0, 0, 0, 0,
5, 5, 15, 15, 5, 5, 0, 0,
0, 0, 12, 12, 5, 0, 0, 0,
0, 0, 0, 0, 1, 0, 0, 0}

The positional value of the queen on each square.

◆ Positions_Rook

sbyte [] cgValueModifiers.Positions_Rook
static
Initial value:
=
{
0, 5, 15, 18, 18, 15, 5, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 5, 7, 18,18, 7, 5, 0}

The positional value of the rook on each square.

◆ Value_Bishop

const int cgValueModifiers.Value_Bishop = 3150

The value of a bishop, used by the engine to evalute board states. There seems to be a general consensus that the bishop, especially in the lategame, is slightly better than the knight.

◆ Value_BishopPairBonus

const int cgValueModifiers.Value_BishopPairBonus = 200

A bonus value given for having both bishops. Leading the AI to be less likely to exchange say a bishop for a knight.

◆ Value_Castle

const sbyte cgValueModifiers.Value_Castle = 85

How much having castled is valued at.

◆ Value_CastlingLongRights

const short cgValueModifiers.Value_CastlingLongRights = 15

How much the right to castle long is valued at

◆ Value_CastlingShortRights

const short cgValueModifiers.Value_CastlingShortRights = 22

How much the right to castle short is valued at.

◆ Value_King

const int cgValueModifiers.Value_King = 50000

The value of a king, used by the engine to evalute board states. This value should always be arbitrarily high.

◆ Value_Knight

const int cgValueModifiers.Value_Knight = 3000

The value of a knight, used by the engine to evalute board states.

◆ Value_Pawn

const int cgValueModifiers.Value_Pawn = 1000

The value of a pawn, used by the engine to evalute board states.

◆ Value_Queen

const int cgValueModifiers.Value_Queen = 9000

The value of a queen, used by the engine to evalute board states.

◆ Value_Rook

const int cgValueModifiers.Value_Rook = 5000

The value of a rook, used by the engine to evalute board states.

◆ Value_RookPairBonus

const int cgValueModifiers.Value_RookPairBonus = 200

A bonus value for having both rooks. Leading the AI to be less likely to exchange a rook for say a bishop + 2 pawns, which is valued at 5 same as the rook.


The documentation for this class was generated from the following file: