DeathChests
DeathChests
This plugin is similar to the Death-System of Diablo 2 (and many other RPG games). If you die it will put down a chest at your feet and your whole inventory gets stored in this chest. But this only works if you have enough chests in your inventory (or if you have certain permissions).
This chest is also saved against every player-based attack. So nobody could loot you while you're walking back to your death point. And also the chest doesn't despawn after time.
Features:
- Drop a chest upon death if you have one in your inventory and save your inventory from being destroyed
- Your chest gets signed with your name if there is space for a sign (either on the side or on the top)
- Shift (Sneak) + click the DeathChest to easily reeqiup your inventory
- Protect your items from griefers and other hazards. Nobody can steal your stuff while you're dead.
- Chest gets unlocked after a defineable time (prevent with per player permissions)
- After unlocking the chest you can define a time after this the chest automaticaly gets destroyed (spills content on ground)
Usage:
Just give yourself the permission deathchest.use and carry a chest around to save your items upon death.
Permissions:
Permission Node | Default | Description |
---|---|---|
deathchest.admin | op | Allows access to the /deathchest command |
deathchest.breakothers | false | Allows to loot or break the DeathChest of others |
deathchest.use | true | Allows the usage of DeathChests |
deathchest.use.free | false | You don't need to carry chests with you to use this plugin |
deathchest.use.sign | true | Puts a name-sign on your DeathChest if possible |
deathchest.use.pvp | true | If this is set, players will also drop a DeathChest if they are killed by a player |
deathchest.use.xp | true | If this permission is set, the XP will also be saved (if set in config) |
deathchest.use.noTimeout | op | Removes the Timeout-feature for a specific permission-group if set |
deathchest.compass | true | Allows the usage of the /dc compass command |
Commands:
For every command you need the deathchest.admin permision-node! The main command is "/deathchest", but you can also use "/dc". In the table below there are only the first arguments listed, that defines the command. /deathchest <subcommand> [argument1, ...]
Subcommand | Aliases | Arguments | Description |
---|---|---|---|
reload | Reloads the configuration of the plugin | ||
info | version | Show information about the plugin version | |
clear | [playername] | Clears the DeathChest-Dictionary (removes protection and Sneak+Click-Support) If there is a playername provided it only removes the chests of this player | |
compass | Points your compass to one (the first not picked up) of your DeathChests |
Configuration:
This describes the content of the config.yml:
YML-Node | Default | Description |
---|---|---|
general.autosavePeriod | 900 | This defines the period (in seconds) when the DeathChest-Dictionary gets autosaved |
general.timeout | 900 | The timeout period in seconds. After this period, the chest is accessable to everyone |
general.pickupEmpty | false | If set to true, DeathChests will be picked up as soon as they are emptied (after a defineable Timeout) |
general.emptyTimeout | 5 | Time in seconds. After this duration the chests will be automatically put into the players inventory |
general.saveXP | true | This must be set or the save-Xp-function won't work |
general.saveXPRation | 0.75 | Percentage of the experience level that will be kept upon death |
general.fullVanish | 3600 | Time in seconds. After this amount of time AFTER the lock timeout the chest gets destroyed (0 disables this feature) |
Additional Information:
Please tell me any bugs you find and every feature you miss!
Planed feature:
- Define how many gold you loose upon death
- Addition: Gold needed for a deathchest
Also save your XP-Points inside the chest (Release them at picking up the chest)Command to let your compass point to your chest
Frequently reported errors:
If you get an error like:
java.lang.UnsupportedClassVersionError: ... : Unsupported major.minor version 51.0
Update your Java to 1.7 your are using 1.6 or lower!
@tdbruce34
Do they have speciall Permissions or something other than those of your players where it works? This feature has only a dependency on 'deathchest.use.xp' which is normaly active for every player.
Would there be any reason that a player wouldn't get their levels back upon retrieving their deathchest? Or is that something that could be a server or compatibility issue?
It has seemed to happen to only one or two players so far, the others don't seem to have an issue with it.
@Melonking
Look at the last paragraph I just added. It was already asked by someone before.
Getting this error at startup:
22:31:35 [SEVERE] Could not load 'plugins/DeathChests.jar' in folder 'plugins'
org.bukkit.plugin.InvalidPluginException: java.lang.UnsupportedClassVersionError: com/Belkar/DeathChests/DeathChests : Unsupported major.minor version 51.0
at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:155)
at org.bukkit.plugin.SimplePluginManager.loadPlugin(SimplePluginManager.java:305)
at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:230)
at org.bukkit.craftbukkit.CraftServer.loadPlugins(CraftServer.java:222)
at org.bukkit.craftbukkit.CraftServer.<init>(CraftServer.java:198)
at net.minecraft.server.ServerConfigurationManagerAbstract.<init>(ServerConfigurationManagerAbstract.java:50)
at net.minecraft.server.ServerConfigurationManager.<init>(SourceFile:11)
at net.minecraft.server.DedicatedServer.init(DedicatedServer.java:105)
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:378)
at net.minecraft.server.ThreadServerApplication.run(SourceFile:539)
Caused by: java.lang.UnsupportedClassVersionError: com/Belkar/DeathChests/DeathChests : Unsupported major.minor version 51.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:44)
at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:29)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:144)
... 9 more
@Melekaiah
:D Happy to help. I decided to add this feature after having a painfull death in a lava pond (and a stuck forwardkey ...). It made me rage to lose those 45 levels.
The next step will be paying gold to place chests (gold always needed & pay gold if you don't have chests in your inventory)
nice to see the updates and a big thumbs up to the xp addition!. i have one particular user that is going to love you forever ... he dies... alot....
Deathchests are working better now, only got one error in the console, but I think it was because I didn't restart the server after installing the plugin. Haven't seen it since I restarted, however it's not allowing me, on my non-admin test account, to claim everything via Sneak + clicking the chest. It only gives me like 1 or two items instead of all of them, is that normal? I can open it normally to claim them, but if someone were to sneak and click at the same time they'd lose alot of items, and only get like 3 or 4 items. Would this have anything to do with the dictionary autosave? Maybe it's hasn't saved their inv recently enough to save the items? I lowered it to 120 seconds hoping that was it but I haven't noticed a difference. f I'm overlooking something simple, please call me out on it lol. I know I'm running low on sleep so it's very likely I'm missing a simple answer.Seems the dictionary just wasn't saving I think. If it happens anymore after given ample time to save I'll post back, but as of now it's working wonderfully.
Nice feature with the XP ratio too. It's nice to be able to save a percentage of your experience and not feel like the last few hours were a waste! :D
Thanks, Dane
Awesome, downloaded the new version and will post if I find any other bugs! Thanks for the quick fix.
@k1sso
If you are using a fresh bukkit without any plugins then those permissions do not work for you. They are used for "Permission Plugins" like PermissionsEX, etc. If you don't have any of them installed then the second column (Default) is used:
op = only Ops have the permission to use it
true = everyone has the permission
false = nobody has the permission
Hope I could help ;)
@PuneyWhiteBoy
I will try to integrate WorldEdit (since I am to lazy to implement a region-system myself) so you can define regions where deathchests won't drop. It will probably be only the normal Cuboid-Area but I think that's enough to handle your needs.
@tdbruce34
Well that seems awkward... I tested it and that shouldn't occur Could you please send me you config-file and your permission settings (best if you PM me so you don't spam the comments ;)) Is there any Log message when dying or trying to pickup the chests? Maybe there is also some region (from WorldGuard or similar) or a missing permission (like PermissionsEXs 'modifyworld.interact') Just uploaded a new version which should fix this bug (interessting that nobody else reported this bug)
Hi and thank you for what could be a very useful plugin. I am very new to plugins, I just recently installed Bukkit on my small server. My problem is rather basic and lame: What exactly do I write to give myself the permission deathchest.use? Do I write this in the console, in the in-game chat or in some kind of permissions file?
Every time I write what seems to be the right command, I just get the message: "Please look at: http://dev.bukkit.org/server-mods/deathchests/"
So I did, and now I'm here...
Edit: Btw, I am using the latest compatible version of Bukkit, and the latest version of this plugin.
For some reason I can't get my "general.pickupEmpty true" to work. The chests stay and I can't destroy them at all. Anybody have any ideas what could cause this? I've tried reloading and tried restarting.
Apart from that I absolutely love this mod. Nice way to keep item thieves at bay!
Also does anyone know of any reason that a player couldn't claim their own deathchest?
I really like the plugin so far :)
Would it be possible to make a way so you could select a region where the chests do not appear or auto destroy themselves after a set time, as in PvP arenas like a BattleNight where they drop nothing the chest just takes up space.
perfect thank you. I have update the Java and the plugin run perfect. 5 Stars for you!
@TheDaaDee
What Java version are you using? I can't find any evidence that this is specific to my plugin. But I know I used some syntax that was added in Java 1.7 so I think you are running a Java 1.6. (so this error will also occur if you are using Craftbukkit 1.2.5-R5.0) (Type in your shell/cmd "java -version")
@Dustinduse
That's why I put the permission node in there. It isn't really possible to add every arena plugin (or whatever you want that should or should not be included). The only efficient way to do it is on your side (with e.g. WorldGuard) to add location/area based permissions that take the chest-permissions away as soon as you enter a arena. Also the plugin must also provide a API so I can get to the variables i need. I will try to implement support for some (Please tell me HERE)
EDIT: About the chests not going away: Well I forgot about this. I will add it ASAP.
--->
Just adding chest dropping (adding to inventory as soon as they are closed and don't have any items in them any more)EDIT2: Just uploaded the new version
hey with 1.3.1 is that happend
2012-08-17 13:48:17 [INFO] This server is running CraftBukkit version git-Bukkit-1.3.1-R1.0-b2320jnks (MC: 1.3.1) (Implementing API version 1.3.1-R1.0) 2012-08-17 13:48:17 [SEVERE] Could not load 'plugins/DeathChests-1.1c.jar' in folder 'plugins' org.bukkit.plugin.InvalidPluginException: java.lang.UnsupportedClassVersionError: com/Belkar/DeathChests/DeathChests : Unsupported major.minor version 51.0 at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:155) at org.bukkit.plugin.SimplePluginManager.loadPlugin(SimplePluginManager.java:305) at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:230) at org.bukkit.craftbukkit.CraftServer.loadPlugins(CraftServer.java:222) at org.bukkit.craftbukkit.CraftServer.<init>(CraftServer.java:198) at net.minecraft.server.ServerConfigurationManagerAbstract.<init>(ServerConfigurationManagerAbstract.java:50) at net.minecraft.server.ServerConfigurationManager.<init>(SourceFile:11) at net.minecraft.server.DedicatedServer.init(DedicatedServer.java:105) at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:380) at net.minecraft.server.ThreadServerApplication.run(SourceFile:539) Caused by: java.lang.UnsupportedClassVersionError: com/Belkar/DeathChests/DeathChests : Unsupported major.minor version 51.0 at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:634) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:277) at java.net.URLClassLoader.access$000(URLClassLoader.java:73) at java.net.URLClassLoader$1.run(URLClassLoader.java:212) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:205) at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:41) at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:29) at java.lang.ClassLoader.loadClass(ClassLoader.java:321) at java.lang.ClassLoader.loadClass(ClassLoader.java:266) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:334) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:144) ... 9 more
Alright. love the idea of this plugin.. but i have to get rid of it. 1st. I run Mob arena and PVP Arenas... Your plugin needs to integrate with those so that chests dont drop when your in them.... 2nd. Chests NEVER seem to go away? if you making this like an RPG most of those wait till you open your chest clean it out and then they vanish... 3rd. The permission issue i was telling you about. my plugins... "bukkitmanager, buttonwarp, Chestbank, Chestshop, Citizens, Creativegates, Creeperheal, DeathChests, DisguiseCraft, Essentials, Factions, Flight, Logblock, McMMO, MobArena, Multiverse, My Chunk, NoCheatPlus, NoLagg, Phatloots, pvparena, Spamguard, SpawnerEXP, Turnstile, VanishNoPacket, Vault, Votifier, WorldBorder, WorldEdit, WorldGuard" there
@TheDaaDee
@kukelekuuk00
I just tried it. Every feature also works with Craftbukkit-1.3.1 R1.0 so nothing to worry about. I will update the file descriptions but nothing needs to be changed on the plugin itselfs.
Please Update the Plugin. Whe need it we love it but is it runnig on 1.3.1 ?
@lightphoenix2
Could you please provide nearer information. I think you right clicked a chest but I can't find any possibility that this bug can anyhow occur. In this line the current world of the player and the world of the chest gets compared. Do you have multiple worlds and/or deleted or unloaded ones? This is the only possible way I can explain this error since I forgot to check if the world exists. Also: what version are you using (plugin and bukkit)
The next time you post a stacktrace (that strange error report from bukkit) please provide any information you can give (what did you do, list of other plugins, etc...) it helps every developer a lot in analysing the error.