Class BonusInfluence
java.lang.Object
it.polimi.ingsw.eriantys.model.influence.CommonInfluence
it.polimi.ingsw.eriantys.model.influence.BonusInfluence
- All Implemented Interfaces:
InfluenceCalculator
This concrete implementation for the state design pattern involving
InfluenceCalculator
defines the Knight
's CharacterCard
effect.-
Constructor Summary
-
Method Summary
Methods inherited from class it.polimi.ingsw.eriantys.model.influence.CommonInfluence
evaluateColor, evaluateTowers
-
Constructor Details
-
BonusInfluence
-
-
Method Details
-
calculate
public int calculate(Player player, IslandGroup island, Set<Color> ownedProfessors) throws InvalidArgumentException Description copied from interface:InfluenceCalculator
The method evaluates the influence of aPlayer
on a certain island.- Specified by:
calculate
in interfaceInfluenceCalculator
- Overrides:
calculate
in classCommonInfluence
- Parameters:
player
- the main target of the calculationisland
- the game location used for the calculationownedProfessors
- theColor
(s) of the professors which thePlayer
owns- Returns:
- the influence value for the given
Player
on the specified island - Throws:
InvalidArgumentException
- if one or more parameters are illegal
-