C# Class BusinessLogic.Logic.Points.PointsCalculator

Inheritance: IPointsCalculator
Datei anzeigen Open project: NemeStats/NemeStats Class Usage Examples

Public Properties

Property Type Description
FIBONACCI_N_PLUS_2 int>.Dictionary
PERCENTAGE_BONUS_PER_AVERAGE_GAME_DURATION_TIER int

Public Methods

Method Description
CalculatePoints ( IList playerRanks, BoardGameGeekGameDefinition bggGameDefinition ) : PointsScorecard>.Dictionary
PointsCalculator ( IWeightBonusCalculator weightBonusCalculator, IGameDurationBonusCalculator gameDurationBonusCalculator ) : System

Private Methods

Method Description
AwardBasePoints ( IList playerRanks ) : PointsScorecard>.Dictionary
EveryoneLost ( IList playerRanks ) : bool
FibonacciSum ( int endIndex ) : decimal
FibonacciSum ( int fibonacciStartIndex, int finoacciEndIndex ) : decimal
GiveEveryoneNormalPoints ( IList playerRanks, PointsScorecard>.Dictionary playerToPoints ) : void
GiveEveryoneTwoPoints ( IList playerRanks, PointsScorecard>.Dictionary playerToPoints ) : void
RoundUpIfNonNegligible ( decimal valueToRound ) : int
ValidatePlayerRanks ( IList playerRanks ) : void

Method Details

CalculatePoints() public method

public CalculatePoints ( IList playerRanks, BoardGameGeekGameDefinition bggGameDefinition ) : PointsScorecard>.Dictionary
playerRanks IList
bggGameDefinition BoardGameGeekGameDefinition
return PointsScorecard>.Dictionary

PointsCalculator() public method

public PointsCalculator ( IWeightBonusCalculator weightBonusCalculator, IGameDurationBonusCalculator gameDurationBonusCalculator ) : System
weightBonusCalculator IWeightBonusCalculator
gameDurationBonusCalculator IGameDurationBonusCalculator
return System

Property Details

FIBONACCI_N_PLUS_2 public_oe static_oe property

public static Dictionary FIBONACCI_N_PLUS_2
return int>.Dictionary

PERCENTAGE_BONUS_PER_AVERAGE_GAME_DURATION_TIER public_oe property

public int PERCENTAGE_BONUS_PER_AVERAGE_GAME_DURATION_TIER
return int