Class UpgradesTab

java.lang.Object
com.csse3200.game.ui.inventoryscreen.UpgradesTab
All Implemented Interfaces:
InventoryTabInterface

public class UpgradesTab extends Object implements InventoryTabInterface
  • Constructor Summary

    Constructors
    Constructor
    Description
    UpgradesTab(Entity player, MainGameScreen gameScreen)
    Creates an Upgrades tab bound to the given main game screen.
  • Method Summary

    Modifier and Type
    Method
    Description
    com.badlogic.gdx.scenes.scene2d.Actor
    build(com.badlogic.gdx.scenes.scene2d.ui.Skin skin)
    Builds the UI actor tree for the upgrades tab The background is placed using a pixel-perfect placer and scaled to two thirds of the current screen height while preserving aspect ratio.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • UpgradesTab

      public UpgradesTab(Entity player, MainGameScreen gameScreen)
      Creates an Upgrades tab bound to the given main game screen.
      Parameters:
      player - entity holding upgrades information
      gameScreen - main game screen used to unpause and hide the pause menu
  • Method Details

    • build

      public com.badlogic.gdx.scenes.scene2d.Actor build(com.badlogic.gdx.scenes.scene2d.ui.Skin skin)
      Builds the UI actor tree for the upgrades tab The background is placed using a pixel-perfect placer and scaled to two thirds of the current screen height while preserving aspect ratio. An invisible button is overlaid at a fixed pixel rectangle to act as the close hotspot
      Specified by:
      build in interface InventoryTabInterface
      Parameters:
      skin - UI skin used for widget construction
      Returns:
      a root table containing the objectives content