PerfectLootContainers
Turn any vanilla container (chest, barrel, ...) into a fully configurable loot container, with loot tables, cooldown or one-time looting, per-player or shared loot, a wand to assign and clone configurations, an admin UI, robust persistence, and proximity-culled glow particles.
| Version | 1.1.0 |
|---|---|
| Platform | Hytale Server Plugin |
| Languages | EN, FR, ES, DE, IT |
Private commission - not available for sale
Installation
- Stop your server
- Drop
PerfectLootContainers-1.1.0.jarinUserData/Mods/ - Start the server
- Use
/plc help
Getting Started
- Create a loot table:
/plc table create starter - Edit it:
/plc table edit starter, hold an item and click Add entry from held item, then set quantities, weights and the rolls range - Place any vanilla container (it can be empty, its real contents are not used)
- Get the wand:
/plc wand, put it in your hotbar and select it - Press F (the use/interact key) on the container, then in the Loot tab pick your table
- Switch to an empty hand and press F on the container to loot it
Features
- Any container -- chests, barrels, any vanilla container becomes a loot container
- Weighted loot tables -- item pools with min/max rolls per open
- In-game table editor -- add from held item, tune quantity and weight per entry
- Reset modes -- Cooldown (re-rolls after a delay) or One-time
- Scope -- Per-player (own roll each) or Shared (one common pile)
- Loot Wand -- assign by pressing F, sneak + F to clone a config across many containers
- Conditions -- world, hour range, gamemode, permission (invertable)
- Gating -- require a permission and/or a key item (optional consume)
- Glow particles -- proximity-culled, per-container color
- Bulletproof persistence -- loot, cooldowns and partial loot survive restarts
Commands
All commands require the perfectlootcontainers.admin permission.
| Command | Description |
|---|---|
/plc help | Show the command list |
/plc info | Show counts and debug state |
/plc wand | Give yourself the Loot Wand |
/plc table create <name> | Create a loot table |
/plc table edit <name> | Open the loot table editor |
/plc table list | List loot tables |
/plc table remove <name> | Delete a loot table |
/plc list | List every loot container |
/plc tp <#> | Teleport to a loot container |
/plc reload | Reload tables and containers |
/plc setlang <code> | Set language (EN, FR, ES, DE, IT) |
/plc debug [on|off] | Toggle verbose console logging |
Wand interactions
| Action | Result |
|---|---|
| Press F on a container (wand in hand) | Open the configuration menu |
| Sneak + F on a configured container | Copy its config to your clipboard |
| Sneak + F on an empty container | Paste the copied config onto it |
Permissions
| Permission | Description |
|---|---|
perfectlootcontainers.admin | All /plc commands and configuration menus |
Separately, an individual container can require any permission node to be opened (set in its Access tab). That gates looting, not commands.
Loot Tables
A loot table is a reusable pool of items. Many containers can share one table.
- Each entry has an item, a quantity range, and a weight (relative chance, not a percentage).
- Each open performs a random number of rolls between the table's min and max. Every roll picks one entry by weighted random and gives a random quantity in its range.
Example: weights 70 / 20 / 10 give per-roll chances of 70%, 20%, 10%. Rolls 1 to 3 means each open yields between 1 and 3 items.
Editor controls: Min/Max rolls, Add entry from held item, per-entry -Q/+Q (quantity), -W/+W (weight), X (remove), and paging (6 entries per page).
Configuring Containers
Press F on a container with the wand in hand to open a tabbed menu (fixed size, footer always visible):
- Loot -- pick the loot table, jump to its editor
- Rules -- reset mode (Cooldown / One-time), scope (Per-player / Shared), cooldown duration
- Particles -- glow on/off and color
- Access -- permission, key item, consume toggle, edit conditions
Looting behavior
- Cooldown, per-player -- each player loots once per cooldown; the cooldown starts only once they empty the container
- Cooldown, shared -- one common pile that refills after the cooldown; one looter at a time
- One-time, per-player -- each player loots once, ever
- One-time, shared -- looted once, then locked for everyone
Cloning a setup
Configure one container, sneak + F on it to copy, then sneak + F on empty containers to paste the same config (table, mode, scope, cooldown, particles, color, permission, key, conditions). Ideal for placing many identical containers fast.
Conditions & Gating
Three independent gates stack (all must pass): permission, key item, and open conditions.
| Condition | Value | Passes when |
|---|---|---|
| WORLD | world name | player is in that world |
| HOUR_RANGE | from-to (0-23) | current server hour is in range (e.g. 20-2 wraps midnight) |
| GAMEMODE | creative or adventure | player is in that gamemode |
| PERMISSION | permission node | player holds the node |
Up to 5 conditions, combined with AND, each invertable (IS / NOT). The key item is only required and consumed on a fresh open, not when grabbing loot already rolled.
Particles
Floating glow particles mark loot containers. They are sent only to players within about 28 blocks and are throttled, so performance stays clean even with very large numbers of containers. Color is configurable per container (gold, turquoise, red, purple, green, blue, white) and can be toggled off.
Data & Files
Data lives in UserData/Saves/<world>/mods/KatsuyaTV_PerfectLootContainers/ as plain JSON:
| File | Contents |
|---|---|
config.json | language and debug flag |
loottables.json | all loot tables |
containers.json | all container assignments |
sharedstate.json | shared-scope looting state |
playerdata/<uuid>.json | per-player looting state |
State is written on chest close, on disconnect and on shutdown. Edit JSON only while the server is stopped, then use /plc reload or restart.
FAQ
Nothing happens when I press F with the wand
The wand only works in your active hand. Move it to your hotbar and select it. Enable /plc debug on to see its location in the console.
The loot window is empty
The table has no entries, all weights are 0, or the rolls range is 0 to 0. Add entries and set a roll range of at least 1.
The container does not refill
One-time containers loot once. In Cooldown mode the timer starts only after the container is fully emptied.
A player cannot open a container
Checked in order: access permission, conditions, cooldown/one-time, key. With debug on, the console prints the exact reason.