Class ScrapComponent

java.lang.Object
com.csse3200.game.components.Component
com.csse3200.game.components.currency.ScrapComponent

public class ScrapComponent extends Component
Component holding the currency value granted by a single sunlight pickup. Attach to an entity/actor representing a sun if you need ECS-side access.
  • Constructor Details

    • ScrapComponent

      public ScrapComponent()
  • Method Details

    • getValue

      public int getValue()
      Returns:
      configured currency value of this sun
    • setValue

      public ScrapComponent setValue(int v)
      Parameters:
      v - new value; @return this for chaining
    • dispose

      public void dispose()
      Description copied from class: Component
      Called when the component is disposed. Dispose of any internal resources here.
      Overrides:
      dispose in class Component