예제 #1
0
 public static TResult Select <TResult>(this TargetBorder targetBorder, Func <TResult> upper, Func <TResult> bottom)
 {
     if (targetBorder.Name == TargetBorderEnum.UpperName)
     {
         return(upper());
     }
     return(bottom());
 }
예제 #2
0
 public AverageBlackStoneToTargetBorderDistance(IPlayersState playersState, IFieldsGraph actualGraph, int averageDistanceWeight)
 {
     _targetBorder          = playersState.CurrentPlayer.GetTargetBorder(actualGraph);
     _originalDistance      = _targetBorder.GetDistanceFrom(actualGraph.GetWhiteField());
     _averageDistanceWeight = averageDistanceWeight;
 }
예제 #3
0
 public WhiteStoneToBorderDistanceValue(TargetBorder winingBorder)
 {
     _winingBorder = winingBorder;
 }
예제 #4
0
 public BlackStoneToTargetBorderCount(IPlayersState playersState, IFieldsGraph actualGraph, int goodBlackFieldsWeight)
 {
     _targetBorder          = playersState.CurrentPlayer.GetTargetBorder(actualGraph);
     _originalDistance      = _targetBorder.GetDistanceFrom(actualGraph.GetWhiteField());
     _goodBlackFieldsWeight = goodBlackFieldsWeight;
 }