Backpack Definitions

All your backpack types are defined in .yml files located in the plugins/BackpacksPlus/backpacks/ directory. You can create multiple files here (e.g., common_backpacks.yml, rare_backpacks.yml) to organize your definitions. The plugin will load all .yml files from this folder.

An example_pack.yml is generated automatically to provide a template.

Structure of a Definition File

Each definition file must start with a definitions: key. Under this key, you list each backpack. The name of each backpack entry MUST be the exact Cosmetic ID from your HMCCosmetics configuration that you want to associate with this backpack.

definitions:
  # This is the Cosmetic ID from HMCCosmetics
  your_cosmetic_id_here:
    slots: 18
    # The number of inventory slots this backpack will have. Must be a multiple of 9 (e.g., 9, 18, 27, 36, 45, 54). Minimum 9, maximum 54.
    gui_title: "&6My Custom Backpack"
    # The title displayed at the top of the backpacks inventory GUI. Supports standard Minecraft color codes.
    allowed-items:
      - "minecraft:stone"
      - "minecraft:diamond_sword"
      # A list of item IDs ("minecraft:stone", "yourplugin:custom_item") that are ALLOWED in this specific backpack type.
      # If this list is empty (allowed-items: []) OR if the allowed-items key is completely missing for a backpack definition, then ALL items will be allowed in that backpack.
      # If you provide a list, ONLY items from that list (and their NBT variants) can be placed in the backpack.

  another_cosmetic_id:
    slots: 9
    gui_title: "&cSmall Pouch"

Last updated