Index   Main   Namespaces   Classes   Hierarchy   Annotated   Files   Compound   Global   Pages  

SpRandomMoveGenerator Class Reference

#include <SpRandomPlayer.h>

Inheritance diagram for SpRandomMoveGenerator:

Inheritance graph
[legend]
List of all members.

Detailed Description

Plays random moves, but does not fill obvious 1-point eyes.

Definition at line 18 of file SpRandomPlayer.h.

Public Member Functions

 SpRandomMoveGenerator (GoBoard &board)
virtual int Score (SgPoint p)
int EvaluateMove (SgPoint p)
 Static move evaluation.
virtual void GenerateMoves (SgEvaluatedMoves &eval, SgBlackWhite toPlay)

Protected Attributes

GoBoardm_board
 Reference to go board on which to play.


Constructor & Destructor Documentation

SpRandomMoveGenerator::SpRandomMoveGenerator ( GoBoard board  ) 

Definition at line 22 of file SpRandomPlayer.h.


Member Function Documentation

int SpStaticMoveGenerator::EvaluateMove ( SgPoint  p  )  [virtual, inherited]

Static move evaluation.

Implements SpMoveGenerator.

Definition at line 42 of file SpMoveGenerator.cpp.

References GoBoard::IsLegal(), SpMoveGenerator::m_board, and SpStaticMoveGenerator::Score().

void SpMoveGenerator::GenerateMoves ( SgEvaluatedMoves eval,
SgBlackWhite  toPlay 
) [virtual, inherited]

Reimplemented in SpDumbTacticalMoveGenerator, and SpLadderMoveGenerator.

Definition at line 18 of file SpMoveGenerator.cpp.

References SgEvaluatedMoves::AddMove(), SpMoveGenerator::EvaluateMove(), SpMoveGenerator::m_board, SgEvaluatedMoves::Relevant(), and GoBoard::SetToPlay().

Referenced by SpSimplePlayer::GenMove().

int SpRandomMoveGenerator::Score ( SgPoint  p  )  [virtual]

Implements SpStaticMoveGenerator.

Definition at line 14 of file SpRandomPlayer.cpp.

References GoBoard::IsEmpty(), GoBoard::IsLegal(), GoEyeUtil::IsSinglePointEye(), SpMoveGenerator::m_board, and GoBoard::ToPlay().


Member Data Documentation

GoBoard& SpMoveGenerator::m_board [protected, inherited]

Reference to go board on which to play.

Definition at line 35 of file SpMoveGenerator.h.

Referenced by SpSafeMoveGenerator::Evaluate(), SpMinLibMoveGenerator::Evaluate(), SpMaxEyeMoveGenerator::Evaluate(), SpInfluenceMoveGenerator::Evaluate(), SpGreedyMoveGenerator::Evaluate(), SpCaptureMoveGenerator::Evaluate(), SpAverageMoveGenerator::Evaluate(), SpStaticMoveGenerator::EvaluateMove(), Sp1PlyMoveGenerator::EvaluateMove(), SpDumbTacticalMoveGenerator::GenerateAttackMoves(), SpDumbTacticalMoveGenerator::GenerateDefendMoves(), SpMoveGenerator::GenerateMoves(), SpLadderMoveGenerator::GenerateMoves(), SpDumbTacticalMoveGenerator::GenerateMoves(), SpMaxEyeMoveGenerator::Heuristic(), SpMinLibMoveGenerator::LibertyMinimum(), Score(), and SpLibertyMoveGenerator::Score().


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


17 Jun 2010 Doxygen 1.4.7