Package it.polimi.ingsw.eriantys.model
Class ProfessorOwnership
java.lang.Object
it.polimi.ingsw.eriantys.model.ProfessorOwnership
This class represents the association between each
Color
's professor and its respective owner.
It exposes a method to get all the professors owned by a Player
,
two methods to activate and deactivate the effect of the Farmer
character card,
and a method to update the professors owners after a movement of students.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Activates theFarmer
character card's effect.void
Deactivates theFarmer
character card's effect.A helper-getter method to fulfill theBoardStatus
creation process.getProfessors
(Player player) Returns theColor
of the professors owned byplayer
.void
Updates the owner for each professor whose respectiveColor
is contained intarget
.
-
Constructor Details
-
ProfessorOwnership
-
-
Method Details
-
getProfessors
Returns theColor
of the professors owned byplayer
. -
activateEffect
public void activateEffect()Activates theFarmer
character card's effect. -
deactivateEffect
public void deactivateEffect()Deactivates theFarmer
character card's effect. -
update
Updates the owner for each professor whose respectiveColor
is contained intarget
. -
getOwnership
A helper-getter method to fulfill theBoardStatus
creation process.
-