DeadMansChest
Ever go out mining or fall into a pit of lava, or somehow die? Ever wish there was an easier way to find your stuff or that it stuck around longer after death? Introducing Dead Man's Chest! With non-destructive glowstone towers (configurable) with a configurable height so you can easily find your stuff! Best of all the glowstone doesn't drop anything when mined (default), so you don't have to worry about players dying just to get free glowstone! This is the official continuation of the PlayerChestDeath plugin on the forum. I have contacted the original author by email and have official approval to do whatever I want with this plugin.
Features
- No death chest if the player doesn't have anything
- An option to require players to have a chest (or two for a double chest) in their inventory upon death to get a death chest.
- An option to have doublechest death chests! (with permissions support)
- Quick loot death chests!
- Death chests disappear instantly after being quick looted
- Permissions support!
- Option to have a non-destructive glowstone tower over your chest
- Configurable glowstone tower height
- LWC locking support
- Option to have death chests disappear after a certain time
- Option to have the rest of your items that don't fit in the chest drop on the ground naturally or to just disappear
- Very configurable!
Permissions (Defaults to everyone, unless otherwise noted)
- deadmanschest.freechest - If you have the option enabled that players must have a chest in their inventory to get a death chest, this one exempts this group from that requirement (Defaults to OPs only)
- deadmanschest.chest - Allows you to have a death chest.
- deadmanschest.drops - Allows anything that doesn't fit in the chest to drop naturally.
- deadmanschest.message - Announce this player's death.
- deadmanschest.lock - If LWC is enabled this player can get a locked chest.
- deadmanschest.beacon - Allows a beacon tower to be built for this player.
- deadmanschest.nodelete - Exempts this player's chests from being deleted. (Defaults to OPs only if no permissions detected)
- deadmanschest.loot - Allows the player to loot locked death chests not belonging to that player. (Defaults to OPs only)
- deadmanschest.doublechest - Allows the player to have a doublechest death chest. (Defaults to everyone)
Configuration
Edit the Config.cfg file found in plugins/DeadMansChest
#Edit this file as needed. #Death Message must be true for the death message String to work!ChestDeleteInterval is in seconds. #NEW! Do players need a chest in their inventory to get a death chest? NeedChestInInventory=false #NEW! How often, in minutes, should we save the death chests? (Set to 0 to disable) ChestSaveInterval=5 # Should we lock chests with LWC LWCEnabled=true #Should the glowstone, chest and sign drop their respective items when mined? MineableDrops=false #Should we build a glowstone tower BeaconEnabled=true #And how high? BeaconHeight=10 #Should the beacon replace water/lava blocks as well or just air blocks? BeaconReplacesLiquid=true #Should we show a death message? DeathMessage=true #Put a sign on the chest with the player name? SignOnChest=true #If we are using LWC to lock the chest should it be a private lock or a public lock? LWCPrivateDefault=true #If death messages are enabled the string to display. DeathMessageString=died and left a chest where he died. #How long before the chest disappears and the items spill out in seconds. ChestDeleteInterval=50 #Should we drop any items normally that don't fit into the chest, or just remove them from the world. DropsEnabled=true #Should we delete the chests after a certain time frame? ChestDeleteIntervalEnabled=true #Should players be allowed to loot death chests when they sneak click on one? # Players can only loot their own chests if LWC protection is set to private # or to loot any chest with lwc they need the deadmanschest.loot permission node. ChestLoot=false #Do not change anything below this line unless you know what you are doing! version = 0.8
I can not for the life of me figure out how to quick loot a chest... Please explain.
@muggerfugger
I am using the plugin with PermissionsEX on my server. It should work fine. If needed you can always open up a thread in the forum and we can work out your issue there as well.
has anyone been able to get this to work with PermissionsEX? I added the stuff to the yml file but still didnt work. :(
Hi, we got a lot of problems, often chest dont despawn, only the protection disappers.
Sometimes Users (#edit "Youser" omg whas that late... -.-) tell me there, wouldn't be their items in the chest.
@bman87
Could you get specifics as to where they died? This error should never appear because I always turn the block into a sign before doing the cast. (Stupid bukkit...) If you want to take a shot at it here's the code it's messing up on: https://github.com/Tux2/PlayerChestDeath/blob/master/src/com/wesnc/playerchestdeath/CreateChest.java#L118
16:08:18 [WARNING] Task of 'DeadMansChest' generated an exception java.lang.ClassCastException: org.bukkit.craftbukkit.block.CraftBlockState cannot be cast to org.bukkit.block.Sign at com.wesnc.playerchestdeath.CreateChest.run(CreateChest.java:118) at org.bukkit.craftbukkit.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:137) at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:493) at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:425) at net.minecraft.server.ThreadServerApplication.run(SourceFile:457)
Some players are unable to get DeathChests now.. this is the error I see.
@Tux2
Excellent news!
Yeah, I should have looked at your other plugins to see that you've done a bunch. Its just I have seen some poorly coded plugins on this site :)
Also, this plugin is exactly what I was planning on making myself, I am glad you're supporting this! :D
@bman87
I will definitely add that in the next version. As far as Java goes I am a Java veteran. With over 7 years of Java experience I should know what I'm doing, but thanks for the offer. ;) As far as the chests not deleting themselves that's the Bukkit scheduler messing up. (I hate it when it does that...) Either that or you aren't getting 20 ticks per second on your server and you need to adjust the amount of time to adjust for that. In the next version I'll also be implementing my own thread to track and delete the chests so that I don't have any more Bukkit scheduler problems to deal with.
Hi, can you make it so any death chests are tracked when the server shutdown or restarted? -Players can get free glowstone, chests, and signs once the server restarts..
Also, I have my chests delete interval set to 1 hour (3600) and it doesn't seem to be automatically deleting them.
(I can help you with Java, and mySQL/SQLite if you are not familiar.)
@formmethanal
You must have the mineable drops set to true, or don't have it set so that the chests disappear. Because I've never had the glowstone be mineable unless I restarted the server while some of the chests were still there. Also, the chests can be auto protected by LWC as well.
Is it possible to protect the created blocks? Especially the glowstone, some users use it as a glowstone source i think i've to remove the beacon.
@Tux2
Ah, so that seems to be because of op. I'll have a closer look at it and then tell you in a ticket if there are still problems ;)
@Folas1337
yes, open a ticket with your craftbukkit version, other plugins installed, and your deadmanschest config file and I will take a look. Also, just FYI: if you are an OP your chest does not disappear by default, so you need to specifically deny the node deadmanschest.nodelete to those people. I have a feeling that's why chests don't disappear after the time limit. As far as not disappearing on loot? That's a different issue all together.
@Tux2
I think if you'll implement that it's fine. Another feature you could add is something like "/dmc list" so you can get the coordinates for your chest (admins could then find the chest for you or something). Then there is a problem about chests disappearing. They simply don't disappear on my server. I'm not sure if that's a known bug or something new, but I'll list plugins + version of CB if you need it and add a ticket as well ;)
@Folas1337
Well, during testing, and on my server, when you quick loot a chest it does disappear, chest and all. If you could open up a ticket for this and let me know what version of Craftbukkit you are using, your other plugins, and the DeadMansChest config file I will investigate the issue for you and see if I can get that solved.
The sign dropping off the chest is a known bug and one that I have yet to come up with a good solution for. (It's also noted in the known caveats section of both versions.)
I'll also look at adding an option for an auto looting when interacting with the chest in any manner as an optional feature as well.
@Tux2
At the moment only the content of a chest disappears but I want the whole chest to disappear and the sign.
Another bug I've encountered is that signs drop if you destroy the chest first.
One more feature request I have is that you should add quicklooting with no matter what you hit the chest with (right- or left-click) and you do not have to crouch (press shift). And the chest should also disappear if you quickloot it. Then it would be perfect... *is sad about the dead cenotaph-plugin :'(*
@DaanSterk
If you were to make a group (group b) that inherited permissions from the default group all the same restrictions that you denied the default group would be denied to that group (group b) as well unless you specifically allowed them for that group and all the groups that inherit from it.
Let's say I give all permissions to default group, and make them negative by placing a '-' in front of every permission, so nobody has them. Can I make a new group under the default group, with some of the positive permissions, enabling them for only that group?
Like, does it read the permissions file down from line to line and take the last permission node for granted if there are more of the same nodes in one file?
I have no idea how else to explain this :l
To disable a group from having a death chest you have to add what's called a negative node to that group. Here's the page in the essentials wiki that describes how to do it. http://ess.khhq.net/wiki/Group_Manager#Negative_nodes
No matter what I try, it defaults to everyone (I'm using GroupManager). What can I do to prevent this?