# ⚒️ Mines

Mines are essential to the prison gameplay experience. Vortex Prison Core offers comprehensive mine management features.

**Mine Access**

Each rank unlocks access to a new mine (A-Z), with higher ranks providing access to more valuable resources.

**Setting Up Mines**

1. Select an area using the mine selector tool (`/mine selector`)
2. Create a mine with `/mine create <id>`
3. Configure the mine settings in the config file
4. Reset/refill the mine when needed with `/mine reset <mine>`

**Mine Conversion**

If you're migrating from Catamines v3, you can convert existing mines using `/mine convert`.<br>

### **Mine Refill System**

The mine refill system automates resource regeneration, ensuring players always have materials to mine.

#### **Key Features:**

* **Automatic Refills** – Mines refill at set intervals.
* **Customizable Blocks** – Define block spawn rates per mine.
* **Adjustable Performance Settings** – Optimize refill speed to suit your server.

#### **Mine Configuration (`config.yml`)**

```yaml
Settings:
  Refill Task Interval: 20 # ticks - Check for new mines to refill every x ticks
  Max Blocks Per Tick: 100000 # Maximum blocks to refill per tick
  Debug Refill Time: false # Enable for debugging refill performance

Mines:
  A:
    Name: A
    World: world
    Lower Corner: 60,62,-17
    Upper Corner: 71,59,-9
    Refill Type: TIME
    Refill: 1m
    Blocks:
    - STONE:20.0
    - COAL_ORE:80.0

  B:
    Name: B
    World: world
    Lower Corner: 63,66,-1
    Upper Corner: 74,63,7
    Refill Type: TIME
    Refill: 1m
    Blocks:
    - EMERALD_ORE:100.0
```

#### **Explanation of Config Options:**

* `Refill Task Interval` – How often the plugin checks for mines to refill (in ticks).
* `Max Blocks Per Tick` – The maximum number of blocks replaced per tick to optimize performance.
* `Debug Refill Time` – Enable debugging to monitor refill efficiency.
* **Mine Settings:**
  * `Lower Corner` & `Upper Corner` – Defines the mine area using coordinates.
  * `Refill Type` – Determines how the mine refills (`TIME` for interval-based, `PERCENTAGE` for depletion-based).
  * `Refill` – Time interval before the mine refills (e.g., `1m` for 1 minute).
  * `Blocks` – Specifies block types and their spawn percentages.

#### **Example Refill Types:**

* **Time-based refill:** Refills every set duration (e.g., `1m`, `5m`).
* **Percentage-based refill:** Triggers when a specific percentage of the mine is depleted.


---

# 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://wiki.vortexdevelopment.net/projects/vortexprisoncore/mines.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.
