Class Building8

All Implemented Interfaces:
BuildingEffect, Serializable, Cloneable

public class Building8 extends BuildingCard
At the end of the game, you gain double the Prestige Points indicated on the Builder cards in your tribe.
See Also:
  • Constructor Details

    • Building8

      public Building8(int era, int price, int prestigeValue)
      Constructor of the building
      Parameters:
      era - The game era of the building.
      price - The price (in food) of the building.
      prestigeValue - The number of Prestige Points gained from this building at the end of the game.
    • Building8

      public Building8(String idIMG, int era, int price, int prestigeValue)
      Constructor of the building.
      Parameters:
      idIMG - the image identifier of the building.
      era - the game era of the building.
      price - the price in food of the building.
      prestigeValue - the number of Prestige Points gained from this building at the end of the game.
  • Method Details

    • clone

      public BuildingCard clone()
      Method to clone the building: it creates an exact copy.
      Overrides:
      clone in class BuildingCard
      Returns:
      The new copy of the building.
    • applyEffect

      public void applyEffect(Player player) throws IllegalArgumentException
      Applies the building effect by granting additional Prestige Points equal to the Prestige Value of each Builder card owned by the player.

      This effectively doubles the contribution of Builder cards to the final score.

      Overrides:
      applyEffect in class BuildingCard
      Parameters:
      player - The player who owns the building.
      Throws:
      IllegalArgumentException - Thrown if the specified player does not own this building.