Skip to content

config.yml

Save interval, fragments and their sources, cube price and animation, lore addons, consolation prizes and sounds.

Global settings. After editing, run /miraclecubeadmin reload.

config.yml is read exactly as written: nothing from the shipped copy is layered underneath. A consolation prize, lore line or sound you delete stays deleted after a reload. Keep every top-level section (Settings, Fragments, Fragments.Events, Cube, Cube.Animation, Lore-Addons, Random-Rewards) present, though; the defaults below only apply to a missing key inside a section.

Settings:
Save-Interval: 60
Key Default Description
Save-Interval 60 Seconds between saves of changed player data to SQLite. 0 or less turns the timer off, leaving saves on quit, shutdown and payouts. Wins and consolation prizes are always saved immediately regardless of this.

How fragments are earned. Fragments are the currency spent decrypting cubes. A walkthrough is in Tuning Fragments.

Fragments:
Chance: 5.0
Min-Amount: 1
Max-Amount: 1
Ignore-Creative: true
Worlds: []
Blocks: []
Events:
Block-Break: true
Block-Place: false
PinnaPrison: false
EdDungeons: false
RivalHarvesterHoe: false
Key Default Description
Chance 5.0 Percent chance per event to award fragments. 100 awards on every event.
Min-Amount 1 Lower bound of each award. Raised to at least 1.
Max-Amount 1 Upper bound, inclusive. Raised to at least Min-Amount.
Ignore-Creative true Players in creative mode earn nothing.
Worlds [] World whitelist, case-insensitive. Empty means every world.
Blocks [] Block whitelist of material names. Empty means every block. An invalid name fails the load.

A player whose profile is not loaded yet (the first moments of a join) is skipped. Balances cap at 2,147,483,647 instead of overflowing.

Each key toggles one fragment source. The toggle is read each time the event fires, so /miraclecubeadmin reload applies a change without a restart.

Key Default Source
Block-Break true A player breaking a block. Cancelled breaks are ignored. Blocks a player placed never roll.
Block-Place false A player placing a block. Every placement rolls, so it can be farmed.
PinnaPrison false PinnaPrison’s block mine event.
EdDungeons false EdDungeons’ sword swing event.
RivalHarvesterHoe false RivalHarvesterHoes’ block break event.

The last three register only when their plugin is enabled at startup, and log a Hooked <plugin>. line when they do. Turning one on without the plugin installed does nothing.

Player-placed blocks are remembered per chunk while Block-Break is on (only for materials the Blocks list allows), so placing and breaking the same block cannot farm fragments.

The price of a decrypt and the reveal animation.

Cube:
Price: 10
Animation:
Cycle-Ticks: 4
Duration-Ticks: 50
Reveal-Ticks: 40
Key Default Description
Price 10 Fragments charged per cube click. 0 makes decrypting free. Negative values count as 0.
Animation.Cycle-Ticks 4 Ticks between icon swaps during the spin. Lower spins faster. Minimum 1.
Animation.Duration-Ticks 50 How long the spin runs before the outcome is revealed (50 ticks = 2.5s). Minimum 1.
Animation.Reveal-Ticks 40 How long the outcome is held on screen after the spin (40 ticks = 2s). On a win, the select menu opens when this ends. Minimum 1.

The spin cycles through the Random-Rewards icons, then lands on the real outcome: the consolation prize’s icon, or the reward’s icon on a win.

The price is charged when the cube is clicked. The payout (commands and message) happens at the reveal, and if the menu closes first it is paid out on the spot, so nothing is lost.

Lines appended to every reward icon in the select menu, after the reward’s own Display.Lore. Which block is used depends on whether the reward is selectable at the player’s current stage.

Lore-Addons:
Unlocked:
- "&8Miracle Cubes"
- " "
- "&7Track down this hidden reward"
- "&7to complete the current board."
- " "
- "&3 - &bStage: &a{stage}&8/&c{required}"
- " "
- "&e➥ Click to select!"
Locked:
- "&8Miracle Cubes"
- " "
- "&7Track down this hidden reward"
- "&7to complete the current board."
- " "
- "&3 - &bStage: &a{stage}&8/&c{required}"
- " "
- "&c&lLOCKED"
- "&4➥ This stage is locked for you!"
Key Default Used when
Unlocked the lines above The reward can be selected at the player’s stage.
Locked the lines above The player’s stage is not a multiple of the reward’s Stage.

Tokens: {stage} (the player’s current stage) and {required} (that reward’s Stage multiple). An empty list appends nothing.

The weighted consolation prizes paid out for decrypting a wrong cube. Their icons are also the pool the spin animation cycles through. Each key is an id.

At least one entry is required - an empty section fails the load.

Random-Rewards:
Fragments-Small:
Weight: 40
Display:
Material: PRISMARINE_SHARD
Name: "&b&lx3 &3&lFragments"
Commands:
- "[fragments] 3"
Fragments-Medium:
Weight: 20
Display:
Material: PRISMARINE_CRYSTALS
Name: "&b&lx5 &3&lFragments"
Glow: true
Commands:
- "[fragments] 5"
Money-Small:
Weight: 25
Display:
Material: EMERALD
Name: "&a&l$10,000"
Commands:
- "eco give {player} 10000"
Exp-Bottles:
Weight: 15
Display:
Material: EXPERIENCE_BOTTLE
Name: "&e&l16x &6&lXP Bottles"
Glow: true
Commands:
- "give {player} experience_bottle 16"
Key Default Description
Weight 1 Relative weight, raised to at least 1. The roll is bounded by the sum of every weight, so these are ratios, not percentages.
Display required The icon, a standard menu item. Its Name is what {reward} shows in RANDOM-REWARD-WON.
Commands [] Run at the reveal. Console commands with {player} replaced, or [fragments] <amount> to credit fragments.

With the defaults the weights total 100, so they read as percentages. Any scale works.

Named sounds in "NAME;volume;pitch" form. volume and pitch are optional and default to 1. NAME is a Bukkit sound name (ENTITY_BAT_TAKEOFF) or a sound key (entity.bat.takeoff); an unknown name fails the load. Set a key to "" or delete it to silence it.

Inventories-Sounds:
"MENU-OPEN": "ENTITY_BAT_TAKEOFF;1;0.5"
"REWARD-SELECTED": "ENTITY_PLAYER_LEVELUP;1;1.5"
"CUBE-DECRYPT": "ENTITY_CHICKEN_EGG;1;1"
"ANIMATION-TICK": "UI_BUTTON_CLICK;1;1.5"
"RANDOM-WON": "ENTITY_EXPERIENCE_ORB_PICKUP;1;1.5"
"REWARD-WON": "UI_TOAST_CHALLENGE_COMPLETE;1;1"
"FRAGMENT-FOUND": "ENTITY_EXPERIENCE_ORB_PICKUP;0.6;1.8"
"DENY": "ENTITY_VILLAGER_NO;1;0.5"
Key Played when
MENU-OPEN Either menu opens (including the select menu reopening after a win).
REWARD-SELECTED A reward is selected in the select menu.
CUBE-DECRYPT A cube click is accepted and the spin starts.
ANIMATION-TICK Each icon swap during the spin. Fires often, so keep the volume low.
RANDOM-WON A consolation prize is revealed.
REWARD-WON The hidden reward is revealed.
FRAGMENT-FOUND Fragments drop from any source.
DENY A click is refused (locked reward, not enough fragments, win still revealing).

The temporary icons flashed on a refused click are not in this file; they live in each menu file. See menus.