Class EffectTracker

java.lang.Object
it.polimi.ingsw.Model.EffectTracker
All Implemented Interfaces:
Serializable

public class EffectTracker extends Object implements Serializable
CharacterCards may impose some non immediate effects to resolve during the turn. This class aims to keep track of them
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      See Also:
    • deniedPawnColour

      private OptionalValue<PawnColour> deniedPawnColour
    • denyTowerInfluence

      private boolean denyTowerInfluence
    • increasedInfluence

      private boolean increasedInfluence
    • increasedMotherNatureMovement

      private boolean increasedMotherNatureMovement
    • alternativeTeacherAssignment

      private boolean alternativeTeacherAssignment
  • Constructor Details

    • EffectTracker

      public EffectTracker()
      Constructor for the Tracker (all effects are disabled)
  • Method Details

    • reset

      public void reset()
      When called, this method will reset all effects to the disabled state.
    • enableIncreasedInfluence

      public void enableIncreasedInfluence()
      enables the increased influence flag
    • enableDenyTowerInfluence

      public void enableDenyTowerInfluence()
      enables the denied tower influence flag
    • enableIncreasedMotherNatureMovement

      public void enableIncreasedMotherNatureMovement()
      enables the increased mother nature movement flag
    • enableAlternativeTeacherAssignment

      public void enableAlternativeTeacherAssignment()
      enables the alternative teacher assignment algorithm flag
    • isInfluenceIncreased

      public boolean isInfluenceIncreased()
      Returns:
      value of the increased influence flag
    • isTowerInfluenceDenied

      public boolean isTowerInfluenceDenied()
      Returns:
      value of the denied tower influence flag
    • isMotherNatureMovementIncreased

      public boolean isMotherNatureMovementIncreased()
      Returns:
      value of the increased mother nature movement flag
    • isAlternativeTeacherAssignmentEnabled

      public boolean isAlternativeTeacherAssignmentEnabled()
      Returns:
      value of the alternative teacher assignment algorithm flag
    • isPawnColourDenied

      public boolean isPawnColourDenied()
      Returns:
      true if the value of the denied PawnColour is set
    • getDeniedPawnColour

      public OptionalValue<PawnColour> getDeniedPawnColour()
      Returns:
      the denied PawnColour wrapped in a OptionalValue
    • setDeniedPawnColour

      public void setDeniedPawnColour(PawnColour pawnColour)
      sets the denied PawnColour
      Parameters:
      pawnColour - the PawnColour to be denied