# items

Detecta automáticamente el tipo de **cada item** depositado siguiendo este orden de prioridad:

{% hint style="success" %}
\[ CraftEngine → Nexo → ItemsAdder ] → Vanilla
{% endhint %}

## Items Vanilla

Los items vanilla se configuran dentro de `items.vanilla` en el `config.yml`. Cada entrada necesita un **identificador único** que usarás para referenciarlo en los menús.

Para registrar rápidamente el item que tienes en la mano:

```
/deposit admin additem [VAULT|PLAYERPOINTS]
```

{% hint style="warning" %}
Puedes registrar cualquier item vanilla con tres métodos diferentes, pero no lo recomiendo a no ser que su item tenga una de estas propiedades CustomModelData u Items Model.\
\&#xNAN;*Se mejorará la formula en el futuro*
{% endhint %}

***

{% tabs %}
{% tab title="Material" %}

```yaml
items:
  vanilla:
    emerald:
      integration: "VAULT" #or "PLAYERPOINTS"
      value: 1.0
      commands: []
```

{% endtab %}

{% tab title="Item Model (1.21.4+)" %}

```yaml
items:
  vanilla:
    ruby_model:
      item-model: "custom:items/ruby"
      integration: "VAULT"
      value: 1.0
      commands: []
```

{% endtab %}

{% tab title="Custom Model Data (1.21.5+)" %}

```yaml
items:
  vanilla:
    paper_custom_model_data:
      material: PAPER
      model: 1
      integration: "PLAYERPOINTS"
      value: 10
      commands: []
```

{% endtab %}
{% endtabs %}

<table><thead><tr><th width="250"></th><th>Descripción</th></tr></thead><tbody><tr><td><code>material</code></td><td>Material vanilla del item (ej: <code>EMERALD</code>, <code>PAPER</code>)</td></tr><tr><td><code>item-model</code></td><td>Namespace del item model (1.21.4+)</td></tr><tr><td><code>model</code></td><td>Custom Model Data (1.21.5+)</td></tr><tr><td><code>integration</code></td><td>Economía: <code>VAULT</code> o <code>PLAYERPOINTS</code></td></tr><tr><td><code>value</code></td><td>Cantidad que recibe el jugador por cada item depositado</td></tr><tr><td><code>commands</code></td><td>Comandos que se ejecutan al depositar este item (opcional)</td></tr></tbody></table>

{% hint style="warning" %}
**PlayerPoints solo acepta enteros.** Si configuras `value: 1.5` con `PLAYERPOINTS`, el plugin usará automáticamente `1`.
{% endhint %}

{% hint style="danger" %}
**Commands** solo ejecuta comandos cuando ingresa el dinero, pero no cuenta la cantidad que ingresas.

(Ejem: Ejecuta un comando al ingresar **un item**. Ejecuta un comando al ingresar **64 items**.)\
\&#xNAN;*Mejoraremos este sistema si lo solicitan*
{% endhint %}

***

## Items Custom

Soporta los tres principales plugins de items custom del mercado. La configuración es similar en todos: cada item necesita su `id` propio del plugin y un identificador único dentro de CubixDeposit.

Para registrar rápidamente el item que tienes en la mano:

```
/deposit admin additem [VAULT|PLAYERPOINTS]
```

El plugin detecta automáticamente de qué plugin es el item y lo registra en la sección correcta del `config.yml`.

{% tabs %}
{% tab title="CraftEngine" %}

```yaml
items:
  craftengine:
    ce_item_1:
      id: "CubixDeposit:item_CubixDeposit"
      integration: "VAULT"
      value: 1.0
      commands: []
```

{% endtab %}

{% tab title="Nexo" %}

```yaml
items:
  nexo:
    nexo_item_1:
      id: "item_CubixDeposit"
      integration: "VAULT"
      value: 1.0
      commands: []
```

{% endtab %}

{% tab title="ItemsAdder" %}

```yml
items:
  itemsadder:
    ia_item_1:
      id: "CubixDeposit:item_CubixDeposit"
      integration: "PLAYERPOINTS"
      value: 5
      commands: []
```

{% endtab %}
{% endtabs %}

<table><thead><tr><th width="250"></th><th>Descripción</th></tr></thead><tbody><tr><td><code>id</code></td><td>ID del item en su plugin de origen</td></tr><tr><td><code>integration</code></td><td>Economía: <code>VAULT</code> o <code>PLAYERPOINTS</code></td></tr><tr><td><code>value</code></td><td>Cantidad que recibe el jugador por cada item depositado</td></tr><tr><td><code>commands</code></td><td>Comandos que se ejecutan al depositar este item (opcional)</td></tr></tbody></table>

{% hint style="warning" %}
**PlayerPoints solo acepta enteros.** Si configuras `value: 1.5` con `PLAYERPOINTS`, el plugin usará automáticamente `1`.
{% endhint %}

{% hint style="danger" %}
**Commands** solo ejecuta comandos cuando ingresa el dinero, pero no cuenta la cantidad que ingresas.

(Ejem: Ejecuta un comando al ingresar **un item**. Ejecuta un comando al ingresar **64 items**.)\
\&#xNAN;*Mejoraremos este sistema si lo solicitan*
{% endhint %}

***

## Añadir un item a un menú específico

Una vez registrado el item en `config.yml`, añádelo al `allowed-items` de un menú con:

```
/deposit admin setitem <id> <menu>
```


---

# Agent Instructions: 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://victorrodasabarca.gitbook.io/cubixdesposit/configuracion/items.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.
