Index   Main   Namespaces   Classes   Hierarchy   Annotated   Files   Compound   Global   Pages  
Public Attributes

GoBoard::State Struct Reference

Data that can be restored quickly with TakeSnapshot/RestoreSnapshot. More...

List of all members.

Public Attributes

SgPoint m_koPoint
 Point which is currently illegal for simple Ko rule.
SgBlackWhite m_toPlay
 Whose turn it is to play.
HashCode m_hash
 Hash code for this board position.
SgBWSet m_all
SgPointSet m_empty
SgArray< Block *, SG_MAXPOINT > m_block
SgBWArray< int > m_prisoners
 Number of prisoners of each color.
SgBWArray< int > m_numStones
 Number of stones currently on the board.
int m_koLevel
 Number of 'illegal' ko recaptures by m_koColor.
SgArray< int, SG_MAXPOINT > m_color
 The current board position.
SgArray< int, SG_MAXPOINT > m_nuNeighborsEmpty
 Number of black and white neighbors.
SgBWArray< SgArray< int,
SG_MAXPOINT > > 
m_nuNeighbors
 Number of black and white neighbors.
SgArray< bool, SG_MAXPOINT > m_isFirst
 Flag if point has not been modified yet.
bool m_isNewPosition
 Flag if position is definitely new (no possibility of repetition), set to true when move is played at any point for the first time, and set to false at the next capture.

Detailed Description

Data that can be restored quickly with TakeSnapshot/RestoreSnapshot.

Corresponds to the current state, excluding block data (which is stored in the stack m_blockList), data, which is only defined immediately after a function call, ot data, which is not expected to change during a TakeSnapshot/RestoreSnapshot (e.g. rules)

Definition at line 688 of file GoBoard.h.


Member Data Documentation

SgArray<int,SG_MAXPOINT> GoBoard::State::m_color

Flag if point has not been modified yet.

Definition at line 724 of file GoBoard.h.

Referenced by GoBoard::Init(), GoBoard::IsFirst(), GoBoard::Play(), GoBoard::RestoreState(), and GoBoard::SaveState().

Flag if position is definitely new (no possibility of repetition), set to true when move is played at any point for the first time, and set to false at the next capture.

Definition at line 729 of file GoBoard.h.

Referenced by GoBoard::Init(), GoBoard::IsNewPosition(), GoBoard::Play(), GoBoard::RestoreState(), and GoBoard::SaveState().

Number of 'illegal' ko recaptures by m_koColor.

Definition at line 712 of file GoBoard.h.

Referenced by GoBoard::CheckKo(), GoBoard::Init(), GoBoard::KoLevel(), GoBoard::RestoreState(), and GoBoard::SaveState().

Point which is currently illegal for simple Ko rule.

Definition at line 691 of file GoBoard.h.

Referenced by GoBoard::Init(), GoBoard::IsLegal(), GoBoard::KillBlock(), GoBoard::KoPoint(), GoBoard::Play(), GoBoard::RestoreState(), and GoBoard::SaveState().

Number of black and white neighbors.

Definition at line 721 of file GoBoard.h.

Referenced by GoBoard::AddStone(), GoBoard::HasNeighbors(), GoBoard::Init(), GoBoard::IsLibertyOfBlock(), GoBoard::NumNeighbors(), and GoBoard::RemoveStone().

Number of black and white neighbors.

Definition at line 718 of file GoBoard.h.

Referenced by GoBoard::AddStone(), GoBoard::HasEmptyNeighbors(), GoBoard::Init(), GoBoard::NumEmptyNeighbors(), and GoBoard::RemoveStone().

Number of prisoners of each color.

Definition at line 706 of file GoBoard.h.

Referenced by GoBoard::Init(), GoBoard::KillBlock(), GoBoard::NumPrisoners(), and GoBoard::RestoreKill().


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


Sun Mar 13 2011 Doxygen 1.7.1