Class ItemPickupComponent

java.lang.Object
com.csse3200.game.components.Component
com.csse3200.game.components.ItemPickupComponent

public class ItemPickupComponent extends Component
A component responsible for handling item pickups in the game.
  • Constructor Details

    • ItemPickupComponent

      public ItemPickupComponent(short targetLayer)
      Constructs an ItemPickupComponent with the specified target layer for item collisions.
      Parameters:
      targetLayer - The layer to target for item collisions.
  • Method Details

    • create

      public void create()
      Initializes the ItemPickupComponent and sets up collision event listeners for item pickups.
      Overrides:
      create in class Component