Repository navigation
Attachments
The Attachments addon is an optional premium add-on for X-Prison that adds a collectible, tiered boost to enchant proc chance. An attachment raises how often one enchant fires, and its power comes from two things: a tier, which sets a value band, and a random roll inside that band made once when the attachment is created and then frozen forever.
That roll is what makes attachments tradeable. A Tier 7 that rolled +0.71x and a Tier 7 that rolled +0.89x look identical in a list and are worth very different money in a trade — so "is this one better than the one on my pick?" is a real question every time a player opens a crate.
The important difference from Crystals: attachments live in the pickaxe, not on the account. A traded, gifted or sold pickaxe arrives with exactly what its owner fitted, and a player who loses the pick loses them with it. That risk is what makes a fully kitted pickaxe worth something.
Attachments are never mined and never dropped by the addon. Everything is handed out by you — through crates, ranks, votes, store purchases or /attachments give.
| Requirement | Notes |
|---|---|
| X-Prison |
2026.3.15.1 or newer (1.2.0+) |
| Java 17+ | Required |
| Paper / Spigot | Built against Paper 1.21.8 |
| Enchants module | Required — an attachment boosts an enchant by its internal name |
| PlaceholderAPI | Optional — only needed for the placeholders below |
Storage: un-attached attachments sit in a per-player pouch in your existing X-Prison database, following your
database_typesetting. Attached ones are written into the pickaxe's item data instead, so they travel with the tool. H2, SQLite and MySQL all work with no extra configuration.
- Download
X-Prison-Attachments-*.jarfrom your purchase platform. - Place the JAR inside
plugins/X-Prison/addons/. - Restart the server (do not use
/reload). - Three files are created in
plugins/X-Prison/addons/Attachments/:
| File | What is in it |
|---|---|
attachments.yml |
Settings: slots, tiers, fusing, the boost ceiling, and every attachment type |
attachments-gui.yml |
Every menu — slots, materials, head textures, lore |
attachments-messages.yml |
All 48 player-facing lines, raw MiniMessage |
- Edit to taste, then run
/attachments reloadto apply all three in place.
A file that predates an update is never a hole: anything a later version adds is answered from the copy inside the jar and named once in the console, so your customised menus keep working.
- An attachment is created by an admin command or a crate. At that moment it rolls a random value inside its tier's band and keeps it for life.
- The player either receives it as a physical item (
--item) or straight into their pouch (--store). Clicking one in your inventory stores and fits it in one motion; right-click stores the held stack, and sneak + right-click stores every attachment you are carrying in one pass. - In
/attachments, the player fits attachments to the pickaxe. A pickaxe has a limited number of slots, and there is at most one attachment per enchant. - While fitted, the attachment multiplies that enchant's proc chance:
chance × (1 + value). A0.82roll is+82%more often. - Because it is a multiplier on the chance, it scales with whatever curve the enchant already has — a Tier 7 turns a 2% Nuke into a 3.7% one and a 20% Explosive into a 37% one, with nothing to rebalance.
- Spares of the same tier and enchant can be fused: consume N of tier X to create one of tier X+1, with a fresh roll in the new, higher band.
The boost is applied through XPrisonEnchantPreTriggerEvent, so it raises a chance the enchant already had and nothing else.
Tiers are defined under tiers: and you can add as many as you like. Numbers may have gaps — fusing always moves to the next tier listed.
| Key | Meaning |
|---|---|
min |
Lowest bonus this tier can roll, as a multiplier bonus (0.7 → +70%) |
max |
Highest bonus this tier can roll |
display-name |
Name shown in the tier table (MiniMessage) |
| Tier | Band | Tier | Band |
|---|---|---|---|
| 1 |
0.01x – 0.1x
|
7 |
0.7x – 0.9x
|
| 2 |
0.1x – 0.2x
|
8 |
0.9x – 1.2x
|
| 3 |
0.2x – 0.3x
|
9 |
1.2x – 1.5x
|
| 4 |
0.3x – 0.4x
|
10 |
1.5x – 2.0x
|
| 5 |
0.4x – 0.5x
|
11 |
2.0x – 2.5x
|
| 6 |
0.5x – 0.7x
|
12 |
2.5x – 3.0x
|
Bands overlap on purpose, which keeps low-tier drops meaningful into the mid game. The tier-range card in the menu prints this table straight from your config, and the console warns you if a band overlaps the one below when you did not intend it.
A pickaxe starts with slots.default attachment slots. Two things raise it, and the larger wins:
slots:
default: 3
max: 7
permission: 'xprison.attachments.slots.'-
A slot item — handed out with
/attachments slots, clicked while holding the pickaxe. This is written into the tool, so it is permanent and travels with it. A crate payload in its own right, and one that makes an old pickaxe worth keeping. -
A permission —
xprison.attachments.slots.5gives a rank five slots on every pickaxe its members hold. A granted slot is never written into the tool, so taking the rank away takes the slot back.
An attachment left beyond the line stops boosting but stays clickable, so it can always be detached.
slots.max is the ceiling neither route can pass.
fuse:
enabled: true
confirm: true # ask before consuming
consume: LOWEST # LOWEST | HIGHEST | OLDEST
default-ratio: 3 # 3 of a tier make 1 of the next
ratios:
9: 5 # per-tier override - keeps the top tiers rare-
consumedecides which duplicates are eaten first: the lowest rolled, the highest rolled, or the oldest owned.LOWESTis the friendly default. - Only stored attachments are consumed — a fitted one is never eaten by a fuse.
- Fusing is always a tier upgrade, but the new value is a fresh gamble inside the new band. That is the point.
- Merge All fuses every duplicate a player owns and keeps climbing — nine Tier 1s become three Tier 2s become one Tier 3, in a single action, across every enchant at once, as one removal and one addition however many fuses it took.
Nothing exists in-game unless it is declared here. Each entry maps an attachment to one registered enchant — X-Prison's own, and anything your enchant addons register.
attachments:
explosive:
enabled: true
enchant: explosive
display-name: '<red>Explosive'
material: TNT
custom_model_data: 0
slot: 10 # button slot in the storage menu, -1 hides it
max-boost: 0 # 0 = uncapped, per typeThe shipped config declares 40 types out of the box, covering the core enchants and every enchant addon:
explosive · layer · nuke · laser · tokenfinder · gemfinder · keyfinder · prestigefinder · gangvaluefinder · salary · charity · blessing · keyalls · tokenmerchant · gemmerchant · blockbooster · autosell · blackhole · lightningstorm · meteorstrike · tornado · arcanenova · divinesmite · soulharvest · starfall · frostbite · galecutter · magmasurge · venombloom · ascendant · vanguard · bombfinder · clusterbomb · drill · luckyblock · petfinder · robotfinder · voucherfinder
A type whose enchant is not registered on this server is simply inactive and reported once, in a single console line rather than one warning per type. The storage menu pages itself, so there is no ceiling on how many you declare and no layout to redo when you add one.
Icons follow the enchants. With item.sync-icons-with-enchants: true an attachment takes its material, head texture and custom model straight from the enchant it boosts, so restyling an enchant in the enchants config carries over with nothing to keep in step by hand. Any single type can opt out on its own.
An attachment can only ever raise a chance the enchant already had. X-Prison clamps every proc chance at 100% after this addon has had its say.
| Setting | Default | What it does |
|---|---|---|
boost.max-chance |
0 |
Your own lower ceiling on the boosted chance, in percent, if you would rather a rare enchant stayed rare. 0 defers to X-Prison's own 100% clamp |
max-boost (per type)
|
0 |
Caps one attachment type on its own |
attach.require-target-enchant |
true |
Refuses to fit an attachment to a pickaxe that does not have the target enchant, so nobody spends a Tier 10 on a proc chance that does not exist yet |
Turn require-target-enchant off and players can fit one for an enchant they have not bought yet — it boosts nothing until they do, and starts paying the moment they buy it. That is what you want if attachments are collected and traded ahead of the enchants themselves.
max-chanceis a percentage, and it is a floor as well as a ceiling. It is applied only to enchants that actually have an attachment fitted, asmin(boosted, max-chance). Set it to1.5and a 20% Explosive drops to 1.5% the moment a player fits an attachment to it — so an attachment would make a common enchant fire less often than no attachment at all. Set it above the highest base chance you want boosted, or leave it at0.
| Key | Default | Meaning |
|---|---|---|
enabled |
true |
Master switch; /attachments reload re-reads it |
storage.max-attachments |
500 |
How many attachments one player may keep in the pouch |
pickaxe.search-inventory |
true |
With nothing in hand, search the inventory for a pickaxe |
pickaxe.include-off-hand |
true |
Check the off hand before the inventory |
pickaxe.prefer |
MOST_ATTACHMENTS |
Which pickaxe wins when a player carries several: MOST_ATTACHMENTS, MOST_SLOTS or FIRST. Holding one always overrides it |
attach.allowed-materials |
the six vanilla pickaxes | Which held items may carry attachments. Leave empty to allow any item |
give.default-mode |
STORE |
What /attachments give does with no --item / --store flag |
item.attach-on-click |
true |
Clicking a physical attachment in your inventory stores and fits it |
item.deposit-on-interact |
true |
Right-click stores the held stack; sneak + right-click stores everything |
item.glow |
false |
Enchant shimmer on the item with no enchantment |
placeholders |
true |
Register the PlaceholderAPI expansion |
Attachments cannot be lost to the world. An attachment is drawn as whatever material suits its enchant, and plenty of those are blocks, food or entities — so placing, eating, throwing, bucket-emptying, item-framing, dispensing and crafting with one are all refused. The refusal denies the item's own use rather than the whole click, so a chest still opens with an attachment in hand.
Every menu and every message is fully templated with MiniMessage, and nothing renders italic — fillers, decorations and page arrows included.
| Command | Permission | Description |
|---|---|---|
/attachments |
command.permission (empty by default)
|
Opens your attachment pouch |
/attachments give <player> <enchant> <tier> [amount] [--item|--store] |
xprison.attachments.admin |
Creates attachments. --store works on offline players; --item needs them online |
/attachments take <player> <enchant> <tier> [amount] |
xprison.attachments.admin |
Removes attachments of a tier |
/attachments slots <player> <slots-per-item> [amount] |
xprison.attachments.admin |
Hands out slot-unlock items |
/attachments clear <player> |
xprison.attachments.admin |
Removes every attachment a player owns |
/attachments reload |
xprison.attachments.admin |
Reloads all three config files |
Aliases /attachment and /atc are configurable under command.aliases.
| Permission | What it grants |
|---|---|
xprison.attachments.admin |
Every admin subcommand. Configurable as command.admin-permission
|
xprison.attachments.slots.<n> |
Raises that player's slot count to <n> on every pickaxe they hold. Prefix configurable as slots.permission
|
Player name lookups for offline give, take and clear never touch the main thread.
Crate example — give a random-rolled Tier 7 Explosive attachment as a physical item:
attachments give %player% explosive 7 1 --item
All placeholders use the xprisonattachments identifier and require PlaceholderAPI. <enchant> is the enchant's internal name, as used in the config.
| Placeholder | Returns |
|---|---|
%xprisonattachments_boost_<enchant>% |
Fitted boost as a decimal (0.82) |
%xprisonattachments_boost_percent_<enchant>% |
The same boost as a percentage (82) |
%xprisonattachments_tier_<enchant>% |
Tier of the fitted attachment, 0 if none |
%xprisonattachments_attached_<enchant>% |
true / false
|
%xprisonattachments_stored_<enchant>% |
How many of that enchant's attachments are in the pouch |
%xprisonattachments_best_tier_<enchant>% |
Highest stored tier for that enchant, 0 if none |
%xprisonattachments_stored_total% |
Total attachments held |
%xprisonattachments_storage_max% |
Pouch cap |
%xprisonattachments_slots_used% |
Slots in use on the resolved pickaxe |
%xprisonattachments_slots_total% |
Slots available on that pickaxe |
%xprisonattachments_slots_max% |
The slots.max ceiling |
The boost_*, tier_*, attached_* and both slots_used / slots_total placeholders read the player's current pickaxe, so they return nothing while the player is offline.
Can players mine attachments? No — and that is deliberate. The addon never mints one on its own, so the drop rate stays entirely in your hands via crates, ranks, votes and store commands.
What happens if a player loses or trades their pickaxe? The fitted attachments go with it. That is the design: attachments are bolted to the tool, not to the account, which is what makes a kitted pickaxe worth trading for. Anything still in the pouch is untouched.
Can a player fit two attachments for the same enchant? No. One per enchant per pickaxe, always — that is what makes a loadout a set of decisions rather than a stack.
Are two attachments of the same tier identical? No. Each one rolled its own value inside the tier band when it was created, and that value never changes.
Do attachments stack with Crystals or /multiplier?
They are unrelated layers. An attachment changes how often an enchant fires; crystals and multipliers change what a currency gain is worth. Both apply.
Can an attachment push an enchant to 100%?
X-Prison clamps every proc chance at 100% after this addon has had its say. Set boost.max-chance if you want a lower ceiling, or max-boost on a single type.
What happens when I take away a rank that granted slots? The slots go with it. A permission-granted slot is never written into the pickaxe, so it is always revocable — unlike a slot item, which is permanent once used. An attachment beyond the new line stops boosting but stays clickable so it can be detached.
Is fusing safe?
It consumes the attachments it lists and always produces the next tier up, but the new roll is random inside the new band. Leave fuse.confirm: true on so players see exactly what they are spending first.
Do attachments survive a restart? Yes. The pouch is in your X-Prison database and fitted ones are in the pickaxe's own item data. A pickaxe written by a future version is read forgivingly — a record this build cannot parse costs that one slot and is named once in the console, never the rest of the tool.
Since 1.1.0 Attachments joins the core Season Reset: stored attachments are wiped. Attachment items and attachments on pickaxes are kept. Requires X-Prison 2026.3.14.0+.
Since 1.2.0 the addon follows each player's /xprison language
(X-Prison 2026.3.15.1+). German, Spanish, French and Brazilian Portuguese are included for attachments.yml, attachments-gui.yml and attachments-messages.yml.
An attachment item is written in the language of the player it is given to; menus always follow the player looking at them.
Your edited lines always win. To change a translation, write the line in
plugins/X-Prison/lang/addons/Attachments/<language>/<same file name> - see Translations.
- Home
- Features
- Setup
- Commands & Permissions
- Placeholders
- Logging
- Season Reset
- Translations
- Item Models & Tooltips
- Changelog
- Currencies
- Ranks
- Prestiges
- Rebirths
- Mines
- AutoSell
- AutoMiner
- Enchants
- Pickaxe Levels
- Pickaxe Skins
- Pickaxe Quality
- Pickaxe Settings
- Gangs
- Multipliers
- Blocks
- Bombs
- History
- Mining Stats
- Nicknames
- Battle Pass
- Quests
- Daily Rewards
- Milestones
- Leaderboards
- Boosters
- config.yml
- autominer.yml
- autosell.yml
- block-rewards.yml
- enchants.yml
- currencies.yml
- multipliers.yml
- ranks.yml
- prestiges.yml
- pickaxe-levels.yml
- pickaxe-skins.yml
- pickaxe-quality.yml
- gangs.yml
- mines.yml
- bombs.yml
- blocks.yml
- history.yml
- logging.yml
- mining-stats.yml
- rebirths.yml
- battlepass.yml
- quests.yml
- dailyrewards.yml
- milestones.yml
- leaderboards.yml
- boosters.yml
- efficiency.json
- fortune.json
- unbreaking.json
- haste.json
- speed.json
- fly.json
- nightvision.json
- jumpboost.json
- autosell.json
- tokenfinder.json
- gemfinder.json
- salary.json
- charity.json
- blessing.json
- gangvaluefinder.json
- prestigefinder.json
- explosive.json
- nuke.json
- layer.json
- laserbeam.json
- second-hand.json
- sixth-hand.json
- doomfall.json
- prism-break.json
- gem-merchant.json
- token-merchant.json
- super-token-miner.json
- double-strike.json
- prodigy.json
- blockbooster.json
