> For the complete documentation index, see [llms.txt](https://edseries-plugins.gitbook.io/p/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://edseries-plugins.gitbook.io/p/pinnaprison/tools-and-items/backpacks.md).

# Backpacks

A backpack automatically collects every block a player mines, holds it up to a capacity, and can be sold (manually or via [autosell](/p/pinnaprison/tools-and-items/autosell.md)). Backpacks have upgradeable **tiers** that increase storage and add a block-gain **multiplier**. Configured in `backpacks.yml`.

```yaml
config:
  gui: 'backpack'              # the backpack GUI (guis/backpack.yml)
  item:
    enabled: true
    hotbar-slot: 8
    update-interval: 5         # seconds between hotbar item refreshes
    item:
      material: 'texture-eyJ0…'  # a custom head
      name: '&d&lYour Backpack'
      lore:
        - ' &a* &bStorage: &a{weight} &8/ &c{size}'
        - '&d[ᴄʟɪᴄᴋ ᴛᴏ ᴏᴘᴇɴ ʏᴏᴜʀ ʙᴀᴄᴋᴘᴀᴄᴋ]'
  contents-format: ' &7- &f{name}&7: &e{amount}'
  contents-empty: ' &7- &fEmpty'

backpacks:
  '1':
    size: 10000
  '2':
    size: 50000
    multiplier: 0.2
    cost: { currency: 'money', amount: 1000000 }
```

## `config`

| Key                    | Description                                                                                                      |
| ---------------------- | ---------------------------------------------------------------------------------------------------------------- |
| `gui`                  | The menu opened when clicking the backpack item (`guis/backpack.yml`; contents in `guis/backpack-contents.yml`). |
| `item.enabled`         | Whether the backpack hotbar item is given.                                                                       |
| `item.hotbar-slot`     | The hotbar slot it's locked to.                                                                                  |
| `item.update-interval` | How often (seconds) the item refreshes while mining.                                                             |
| `item.item`            | The item itself. Lore placeholders: `{weight}` (used storage), `{size}` (capacity).                              |
| `contents-format`      | How each stored item renders in the contents menu (`{name}`, `{amount}`).                                        |
| `contents-empty`       | Shown when the backpack is empty.                                                                                |

## Tiers (`backpacks`)

A numbered map of tiers. Tier `'1'` is the default (no cost); higher tiers are bought in order.

| Key                             | Description                                        |
| ------------------------------- | -------------------------------------------------- |
| `size`                          | Storage capacity (max weight) at this tier.        |
| `multiplier`                    | Extra blocks stored per mined block. `0.2` = +20%. |
| `cost.currency` / `cost.amount` | Price to upgrade **into** this tier.               |

## Usage

* **Right-click** the backpack item → open the backpack menu.
* **`/sellall`** (alias `/sellbackpack`) → sell the whole backpack at the [autosell](/p/pinnaprison/tools-and-items/autosell.md) prices.
* Admins: **`/pinna givebackpack <player>`** to (re)give the backpack item.

## Placeholders

```
%pinnaprison_backpack_size%           -> used weight
%pinnaprison_backpack_maxsize%        -> capacity
%pinnaprison_backpack_nextsize%       -> next tier capacity
%pinnaprison_backpack_multiplier%     -> current multiplier
%pinnaprison_backpack_nextmultiplier% -> next tier multiplier
%pinnaprison_backpack_cost%           -> next tier cost
%pinnaprison_backpack_maxed%          -> true/false
%pinnaprison_backpack_currencyname%   -> next tier cost currency
%pinnaprison_backpack_autosell%       -> autosell on/off
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://edseries-plugins.gitbook.io/p/pinnaprison/tools-and-items/backpacks.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
