Chestpack
Chestpack - extra storage in a backpack on your chest!
Need extra storage while traveling? Wear a chest on your chest! Chestpack enables players to craft backpacks of various sizes for augmenting their normal player inventory space. It is designed to enable carrying additional items realistically without being too overpowered.
Features:
- No client mods required
- Crafting recipes to create packs
- Three different types, with configurable material and size
- Optional integrated workbench
- Packs are uniquely identified, and can be opened by id as an admin
- Equip pack as chestplate for storage (optional)
- Hold pack in your hand when picked up (optional)
- Nesting packs within packs is prevented (optional)
- Permissions support
- Somewhat realistic
Usage
Craft a pack by surrounding a chest with one of:
- 4 string = 9-slot pack (daypack)
- 8 wool = 27-slot pack + integrated workbench (craftsman's backpack)
- 8 leather = 45-slot pack (explorer's backpack)
When holding the resulting chest (it appears the same as a normal chest, but is actually a special wearable chest), click to open the pack. You can drag items to/from the pack and your inventory, as you would expect.
If your pack has an integrated workbench, shift-click to open the crafting area.
When it isn't held in your hand, the pack will move itself to your chestplate armor slot, representing the pack being worn on your back as a backpack (or on your chest as a chestpack, whatever interpretation you prefer). This is where the pack normally resides.
To get back into your pack, take it off your back and move it into your hand. Left-click to open it.
Configuration
verbose: Enable logging of different events to console (used for debugging)
checkForUpdates: Control whether the plugin notifies players (with the chestpack.admin permission) of new updates.
allowNesting: If enabled, packs can be stored within packs. When disabled (the default), attempts to nest packs will drop them to the ground.
autoEquip: If enabled, packs will automatically equip in your armor slot, simulating wearing a chestpack, actively preventing you from storing the pack elsewhere in your inventory.
autoHold: If enabled, packs will automatically be held in your hand if placed in your hotbar or picked up from the ground. Along with autoEquip, this option is meant to simulate a pack you can either hold in your hands or wear on your back, but not keep in your "pockets" (other inventory slots). Disable along with autoEquip if you want the pack to (less realistically) behave as a normal item so you can carry multiple packs.
allowOpenContainers: Allows you to still open containers (chests, etc.) by right-clicking, instead of opening the pack.
equipSlot: Player inventory slot to wear the chestpack on if autoEquip enabled. 3 = helmet, 2 = chestplate, 1 = leggings, 0 = boots.
maxSlots: Number of slots to show with /chestpack command.
chestpackItem: The item used to represent a chestpack once crafted
packTypes: A list of the packs to allow crafting for. Each item has several fields:
packTypes base_material: The material used in place of a chest (optional)
packTypes material: The material to craft the pack from (in addition to the base material).
packTypes material_count: Number of material items to require to craft.
packTypes size: Number of slots in the resulting chest. For reference 27 is a small chest, 54 is a large chest.
packTypes hasWorkbench: If true, the pack can be shift-clicked to open an integrated crafting table.
The default configuration is:
verbose: false
allowNesting: false
autoEquip: true
autoHold: true
allowOpenContainers: true
equipSlot: 2
maxSlots: 54
chestpackItem: chest
packTypes:
- {base_material: chest, material: leather, material_count: 8, size: 45}
- {base_material: chest, material: wool, material_count: 8, size: 27, hasWorkbench: true}
- {base_material: chest, material: string, material_count: 4, size: 9}
For the values of base_material and chestpackItem, you must use the values listed here.
Alternatively you can disable Chestpack's recipes and use another plugin to add more complex custom recipes. Simply add a recipe to craft a chest with the following enchantments:
- Fortune I - identifies an empty pack (higher levels are used as unique identifiers)
- Efficiency # - level is number of slots, negated
- Punch - if present, pack has an integrated workbench
Chestpack inventories are stored in separate files, named pack<id>.yml.
Also, this plugin uses PluginMetrics by Hidendra to track plugin usage. All data collected is anonymous and may be viewed here. For the paranoid, this may be disabled by editing plugins/PluginMetrics/config.yml and changing the value of opt-out to true.
Permissions and Commands
chestpack.admin (op): Allows you to open any chestpack with the /chestpack command
chestpack.open.size.9 (true): Allows you to open chestpacks of size 9
chestpack.open.size.18 (true): Allows you to open chestpacks of size 18
chestpack.open.size.27 (true): Allows you to open chestpacks of size 27
chestpack.open.size.45 (true): Allows you to open chestpacks of size 45
chestpack.open.size.54 (true): Allows you to open chestpacks of size 54
chestpack.open.size.any (false): Allows you to open chestpacks of any size
chestpack.open.workbench (true): Allows you to open integrated workbenches
/chestpack id: Opens chestpack with the given id, 2 or greater (aliases: /pack, /cp).
Caveats
The chest pack item shows up as a normal "Chest" in the player inventory. But its behavior should make it clear how it differs (it auto-equips, can be opened, doesn't stack with other chests).
See also
Other mods or plugins worth checking out:
- Backpack - client/server mod with wearable backpacks, magic backpacks
- Forestry - client/server mod with several item-specific backpacks
Fork me on GitHub GitHub of original author, mushroomhostage
Please add permissions to open chests please!
crafting table doesnt seem to work for me I tried arrow_damage 0 and 1 neither worked
could you add an option for custom protection (I want to make it crafted with a diamond chestplate and 8 chests but also have the chestpack provide the same protection as a diamond chestplate and show up on other players screens as if they are wearing a diamond chestplate)
I'm way on board for having it be permissions nodes to open them! I want it for my VIP members!
Any possibility of making the backpack not be automatically selected when picking it up? It's annoying when having two backpacks in inventory and it also makes it impossible to try to put one in chest. Actually, it would be better if when picking a second backpack, it wouldn't try to equip itself over the first one. Also, make it not possible to put a backpack inside itself.
@LordKainzo
Yea, more permission nodes needed. Gonna have it as Premium feature on my server
any ability to prevent players from using this unless they're in a certain group?
Can you please add a config option that changes the plugin so that the backpack goes on your head instead of chest, for two reasons. 1. You can see the chest on a players's head even without client mods. 2. The chest plate armor is more important than the helmet armor, so having the pack on your head would be more armor efficient. Thanks for reading -MCTakeover
2012-03-31 17:58:19 [SEVERE] Could not pass event InventoryCloseEvent to Chestpack org.bukkit.event.EventException at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:303) at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:459) at net.minecraft.server.NetServerHandler.handleContainerClose(NetServerHandler.java:1048) at net.minecraft.server.Packet101CloseWindow.handle(SourceFile:16) at net.minecraft.server.NetworkManager.b(NetworkManager.java:229) at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:113) at net.minecraft.server.NetworkListenThread.a(NetworkListenThread.java:78) at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:554) at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:452) at net.minecraft.server.ThreadServerApplication.run(SourceFile:490) Caused by: java.lang.NullPointerException at me.exphc.Chestpack.ChestpackListener.onInventoryClose(Chestpack.java:112) at sun.reflect.GeneratedMethodAccessor214.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:301) ... 10 more
Awesome :)
Is there a way to make it not equip over armor? I'd rather be able to assign a hotbar slot for it where it just stays.
It also needs a clean way to get RID of a chestpack
Another thing, I don't see a crafting table in the second chest :(
Um quick bug you should make it impossible to put the chestpack in the chestpack inventory...
I forgot which one was my chests and my backpacks now i lost my stuff that was in it
First i get this error:
http://dev.bukkit.org/paste/4989/
second the admin permissions does not run
third is it possible that 1 chest gets 1 file
Hi nice plugin. After backpack plugin was grouped we ended up dropping it because of problems. Would like to see size permission nodes if doing perms so anyone could assign different pack sizes to different groups/classes.
Will try this out later :)
Thank you :D
Can request for more permissions nodes?
chestpack.use - To allow use of chestpack
chestpack.craft - To allow crafting of chestpack