Description
SpinCrate
A fully self-contained crate/lootbox system for server admins — configure everything in-game or from a built-in local web panel, with zero external tools.
SpinCrate turns any vanilla chest into a lootbox: players use a key to spin a slot-machine-style roulette and win a randomly selected reward, weighted by admin-configured rarity tiers. Every part of it — rarities, rewards, keys, cooldowns, sounds, effects — is fully configurable per crate, and can hold literally anything: vanilla items, items from any other installed mod, full NBT-preserving items (including, for example, a captured Pokémon via optional Cobblemon integration), or even server commands.
Opening a crate
- Physical keys — a custom item, one per crate type, must be held in your main hand to open. Master keys open any crate; "rigged" keys guarantee a result within a chosen rarity range.
- Virtual keys — a per-player, per-crate balance that coexists with physical keys. Deposit physical keys into virtual balance, withdraw them back, or open crates directly with Shift + right-click. A plain right-click without a physical key never spends anything — it just shows a preview of the odds and rewards.
- Preview screen — anyone without a key (or on cooldown) can still see exactly what's in the pool and each item's real drop chance.
Rarities and rewards
- Up to 9 rarity tiers per crate, each with an independently configurable weight (down to fractions of a percent) and its own color.
- Any item can be added as a simple
item + count, or as a fully-resolved NBT item (built through the in-game GUI) to preserve enchantments, custom data, or an entire captured Pokémon. - Command-based rewards (run any server/console command as the prize — economy payouts, custom effects, anything).
- A "nothing" outcome is supported, so a rarity slice can represent an empty result without skewing other odds.
- Server-wide broadcast messages when someone wins a sufficiently rare reward.
Ambiance
- Continuous ambient particles around the bound chest, in one of several patterns (ring, flames, fountain, sparks, beam, double helix, vortex, spiral), fully configurable per crate.
- A hidden light source keeps the crate visible without a particle spam.
- A floating hologram shows the crate's name.
- Configurable reveal sounds, tiered by how rare the result was.
Player limits & economy
- Optional per-player opening cooldowns ("N opens every M minutes").
- Optional periodic giveaways: automatically grant virtual keys to every known player on a set interval.
- Full opening history and leaderboards: a "luck index" (weighted by how surprising each result was, not just your best roll), most-active players, and top players per crate.
Admin tools
Everything above is configurable two ways:
- In-game: a full command set (
/crates admin ...) plus a double-chest-style GUI for building the reward pool. - Built-in local web panel — the standout feature. SpinCrate runs its own lightweight web server (loopback-only, nothing exposed outside the host machine) with no setup and no external hosting:
- A dashboard listing every crate at a glance (rarity count, weight total, item count, cooldown/giveaway status).
- A full crate editor with a live item search (by id or translated name, across every installed mod) showing real item sprites, and a searchable sound picker.
- A "global settings" panel to push one setting (effect, sound, cooldown) to every crate at once, without touching each one individually.
- Virtual key management: see every player's total balance, drill into any player to view and directly edit their balance per crate.
- A statistics dashboard: global leaderboards plus a per-player breakdown (total openings, luck index, per-crate counts, paginated opening history).
- Every change applies live — no reload, no restart.
Built to survive crashes
- The reward is rolled and safely written to disk before the roulette animation starts. A server crash, a disconnect mid-spin, or a restart can never lose or duplicate a prize — it's delivered the moment the player is back online.
- A bound chest (and its marker/light) can't be broken by players while it's linked, preventing accidental griefing of active crates.




