> For the complete documentation index, see [llms.txt](https://docs.mongenscave.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mongenscave.com/premium-products/quests/supported-plugins/shopgui+.md).

# ShopGUI+

When [ShopGUIPlus](https://www.spigotmc.org/resources/shopgui-1-8-1-21.6515/) is installed, three shop-based triggers become available. Detection is automatic. Only transactions made through the shop GUI count — trades, other economy plugins and command-based selling don't.

| Trigger      | Counts when the player... | Progress                   |
| ------------ | ------------------------- | -------------------------- |
| `sell_item`  | sells items to the shop   | number of items sold       |
| `buy_item`   | buys items from the shop  | number of items bought     |
| `sell_money` | sells items to the shop   | money earned from the sale |

`sell_item` and `sell_money` fire on the same action — the difference is what they count. Use `sell_item` for "sell 64 wheat" quests and `sell_money` for "earn $10,000 by selling" quests. Sell-all counts too.

### Targets <a href="#targets" id="targets"></a>

All three triggers accept the same `target` values:

* A **material name** (`WHEAT`, `DIAMOND`, ...) — only that item counts.
* **`any`** — every shop transaction counts.
* **`CROPS`** — a built-in group of farm goods, for farming quests without listing every crop:

> `WHEAT`, `CARROT`, `POTATO`, `BEETROOT`, `MELON_SLICE`, `PUMPKIN`, `SUGAR_CANE`, `CACTUS`, `BAMBOO`, `COCOA_BEANS`, `NETHER_WART`, `SWEET_BERRIES`, `GLOW_BERRIES`, `KELP`, `DRIED_KELP`

### Examples <a href="#examples" id="examples"></a>

A farmer quest using the crop group:

```yaml
objectives:
  harvest_sale:
    name: "&#8DFFB3&lMarket Day"
    trigger: sell_item
    target: CROPS
    required: 256
```

A money-target version of the same idea:

```yaml
objectives:
  big_earner:
    name: "&#FFD86E&lBig Earner"
    trigger: sell_money
    target: any
    required: 10000
```

And a buying objective:

```yaml
objectives:
  stock_up:
    name: "&#7CF6FF&lStocking Up"
    trigger: buy_item
    target: ARROW
    required: 128
```

{% hint style="info" %}
`sell_money` progress is counted in whole currency units — the price of each sale is rounded down before it's added.
{% endhint %}
