Class SpoiledPrincess
java.lang.Object
it.polimi.ingsw.eriantys.model.StudentContainer
it.polimi.ingsw.eriantys.model.characters.ContainerCharacterCard
it.polimi.ingsw.eriantys.model.characters.SpoiledPrincess
- All Implemented Interfaces:
- CharacterCard
Represents the "spoiled princess" character card and the corresponding effect.
- See Also:
- 
Field SummaryFields inherited from class it.polimi.ingsw.eriantys.model.characters.ContainerCharacterCardbag
- 
Constructor SummaryConstructorsConstructorDescriptionSpoiledPrincess(Bag bag, Supplier<Player> currentPlayerSupplier) Constructs a newSpoiledPrincesscharacter card.
- 
Method SummaryModifier and TypeMethodDescriptionvoidapplyEffect(List<Color> sourceColors, List<Color> destinationColors, Color targetColor, IslandGroup targetIsland) Activates this card and applies the effect.Methods inherited from class it.polimi.ingsw.eriantys.model.characters.ContainerCharacterCardcancelEffect, getCost, increaseCost, setupEffectMethods inherited from class it.polimi.ingsw.eriantys.model.StudentContainerempty, fill, getQuantity, getRepresentation, moveAllTo, moveTo, moveTo, refillFrom, remainingCapacity, swapMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface it.polimi.ingsw.eriantys.model.characters.CharacterCardgetName
- 
Constructor Details- 
SpoiledPrincessConstructs a newSpoiledPrincesscharacter card.- Parameters:
- bag- Reference to the bag object for the current game.
- currentPlayerSupplier- Supplier to get the current player.
 
 
- 
- 
Method Details- 
applyEffectpublic void applyEffect(List<Color> sourceColors, List<Color> destinationColors, Color targetColor, IslandGroup targetIsland) throws InvalidArgumentException, NoMovementException Description copied from interface:CharacterCardActivates this card and applies the effect. If it is the first time also increases the cost for next activations. Only some arguments might be used for a specific character card effect.- Parameters:
- sourceColors- a list of student colors selected from the source
- destinationColors- a list of student colors selected from the destination
- targetColor- the color selected for the effect
- targetIsland- the island selected for the effect
- Throws:
- InvalidArgumentException- if one or more parameters are illegal
- NoMovementException- if an error occurs while wielding student related movements and swaps
 
 
-