HexProp.cpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006 #include "SgSystem.h"
00007 #include "SgProp.h"
00008 #include "HexProp.hpp"
00009
00010 using namespace benzene;
00011
00012
00013
00014 void HexProp::Init()
00015 {
00016 SgProp* moveProp = new SgPropMove(0);
00017 SG_PROP_MOVE_BLACK
00018 = SgProp::Register(moveProp, "B",
00019 SG_PROPCLASS_MOVE + SG_PROPCLASS_BLACK);
00020 SG_PROP_MOVE_WHITE
00021 = SgProp::Register(moveProp, "W",
00022 SG_PROPCLASS_MOVE + SG_PROPCLASS_WHITE);
00023 }
00024
00025
00026
00027 SgProp* HexProp::AddMoveProp(SgNode* node, SgMove move, SgBlackWhite player)
00028 {
00029 SG_ASSERT_BW(player);
00030 SgProp* moveProp = node->AddMoveProp(move, player);
00031 return moveProp;
00032 }
00033
00034