Class ItemRamShield

    • Constructor Detail

      • ItemRamShield

        public ItemRamShield()
        Creates a new ItemRamShield.
    • Method Detail

      • getItemRating

        public int getItemRating()
        Returns an item value for ComputerFigures rating in the items category.
        Overrides:
        getItemRating in class ItemShielding
        Returns:
        energy * 10.
      • getDrawText

        public java.lang.String getDrawText()
        Returns a display string for UI. Might be null
        Overrides:
        getDrawText in class Item
        Returns:
        +GAIN.
      • isRammed

        public int isRammed​(Figure f,
                            Figure rammer,
                            int power,
                            AnimationInfo animation)
        Reduces the ram power (and the shieldings energy).
        Specified by:
        isRammed in interface FigureRamListener
        Overrides:
        isRammed in class Item
        Parameters:
        f - The figure.
        rammer - The rammer.
        power - The ram power.
        animation - The AnimationInfo.
        Returns:
        The modified ram power.