DiamondHunter
Overview
When a player breaks a Diamond Ore a chat message is sent to all players online with the right permission node to tell them that a player has broken a ore (configurable in config) and where abouts they broke that ore.
Logs to SQLite or MySQL to be easy put in to a report about a player
Great for catching x-rayers or who to watch.
Features
- 1.8 Support
- UUID Support
- MySQL and SQLite support
- Multiple world support
- Logs all ores at once instead of 1 at a time
- Report system to look at what a player has been breaking, where and when.
Install
- Download the latest version of the plugin
- Drop the plugin your plugins folder
- Restart the server
- Edit your config.yml to the settings you wish to have
Permissions and Commands
dh.getnotice - To receive notices when players break a Diamond Ore.
dh.reload - To have permission to reload the server.
dh.exempt - Stops Diamond Hunter announcing and logging your mining.
dh.report - To view report on players
/dh - Information about the plugin.
/dh reload - The command to reload your config.
/dh off - To stop receiving mining notifications.
/dh on - To turn miing notifications back on.
/dh report <player> [page] - To view reports on a player. Page parameter is optional.
Config
For help on setting up your config.yml click the link below
Config
Images
Videos
Big thanks to Sleepspark001 for making the guide. Check out his channel here For Version 2.0.3 and below only
To do
Less chat spamSeparate text files for each world- Option to teleport to the location of where the ore was broken in vanish
Configurable message
Versions
V3.0.0
- Recoded the whole plugin from scratch. Performance should be improved.
- Support for UUID and Minecraft 1.8
- MySQL and SQLite support
- Groups of ores are now displayed instead of 1 at a time
- Report system to view what players have been mining, where and when
- Messages.yml added so you can edit the messages displayed
V2.0.3
- Added the permission node dh.exempt anyone with this permission node will not have their mining announced or logged
- Added /dh off This stops you from receiving Diamond Hunter Notices
- Added /dh on This turns notifications from Diamond Hunter back on
- Fixed the logs saving the wrong information, it now correctly stores the date of the blocks
V2.0.2
- Fixed messages saying your own name instead of the person who mined the block
V2.0.1
- Removed Debugging message, which I managed to upload the wrong version of last upload. I have now uploaded the current version.
V2.0.0
- Recoded the whole plugin. It is now much more efficient and less server intensive.
V1.3.5
- Added custom message for the [DH] tag. Simply go to your new config and change the Tag line to what you wish to have.
IMPORTANT YOU MUST DELETE YOUR CONFIG IF YOU ARE UPDATING FROM A OLD VERSION
V1.3.3
- Added Emerald, Lapis, Redstone, Gold, Iron, Coal to the plugin.
- Updated the config to toggle which ore's you want active and which one's your don't.
- Added option to disable log to file.
- To reload the command is now /dh reload
- For help do /dh
IMPORTANT YOU MUST DELETE YOUR CONFIG IF YOU ARE UPDATING FROM A OLD VERSION
v1.2.0
- Added per world txt files, useful for anyone with multiple worlds. Anyone with just 1 world, you will just have 1 single txt file. Txt files are called whatever the world name is.
- Added a way to reload your config.yml from within game, you no longer have to restart the server for the custom message to change, to reload your config use the command /dh
You need the permission node dh.reload to be able to preform the reload command. Op's get the command without needing the permission node.
v1.1.0
- Added a config.yml to set up your own custom messages
v1.0.0
- Initial relase
It this plugin development still active?
Does this work on MC 1.11.2?
@Jwoolley
Any progress so far?
@hetjoshi
I will see what I can do.
@Jwoolley
Can you make it so that the plugin only detects naturally spawned diamond ore? not ones from silk touch and replaced back and for those it keeps saying I mined diamonds when In reality I just used silk touch on diamond ore and kept placing and breaking and it announce.
@hetjoshi
Thanks for that. I will fix that tonight for you when I get home from work. :)
[17:32:37] [Server thread/INFO]: hetjoshi issued server command: /dh [17:32:37] [Server thread/ERROR]: null org.bukkit.command.CommandException: Unhandled exception executing command 'dh' in plugin DiamondHunter v3.0.0 at org.bukkit.command.PluginCommand.execute(PluginCommand.java:46) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:141) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at org.bukkit.craftbukkit.v1_8_R1.CraftServer.dispatchCommand(CraftServer.java:646) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at net.minecraft.server.v1_8_R1.PlayerConnection.handleCommand(PlayerConnection.java:1115) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at net.minecraft.server.v1_8_R1.PlayerConnection.a(PlayerConnection.java:950) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at net.minecraft.server.v1_8_R1.PacketPlayInChat.a(PacketPlayInChat.java:26) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at net.minecraft.server.v1_8_R1.PacketPlayInChat.a(PacketPlayInChat.java:53) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at net.minecraft.server.v1_8_R1.PacketHandleTask.run(SourceFile:13) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [?:1.8.0_25] at java.util.concurrent.FutureTask.run(Unknown Source) [?:1.8.0_25] at net.minecraft.server.v1_8_R1.MinecraftServer.z(MinecraftServer.java:683) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at net.minecraft.server.v1_8_R1.DedicatedServer.z(DedicatedServer.java:316) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at net.minecraft.server.v1_8_R1.MinecraftServer.y(MinecraftServer.java:623) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at net.minecraft.server.v1_8_R1.MinecraftServer.run(MinecraftServer.java:526) [spigot.jar:git-Spigot-d0d1d87-15e81cf] at java.lang.Thread.run(Unknown Source) [?:1.8.0_25] Caused by: java.lang.ArrayIndexOutOfBoundsException: 0 at uk.co.joshuawoolley.diamondhunter.commandhandler.CommandHandler.onCommand(CommandHandler.java:42) [?:?] at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44) [spigot.jar:git-Spigot-d0d1d87-15e81cf] ... 14 more
Would it be possible to add glowstone? Or perhaps an option to define any kind of block?
Is anyone seeing double entries? I'm running 1.7.9 and people are being logged as mining twice. For example:
[Sun Aug 17 16:46:01 EDT 2014] xx mined a block of Diamond ore at location X: -1225 Y: 12 Z: -173
[Sun Aug 17 16:46:02 EDT 2014]xx mined a block of Diamond ore at location X: -1225 Y: 11 Z: -173
[Sun Aug 17 16:46:29 EDT 2014] xx mined a block of Diamond ore at location X: -1225 Y: 11 Z: -173
[Sun Aug 17 16:49:44 EDT 2014] xx mined a block of Diamond ore at location X: -1225 Y: 11 Z: -173
The first entry is by itself, which is fine, the rest of the entries are all in the same location. What gives? The only way this could happen is if they mined a spot, put a diamond ore block in that same spot, then mined it again. Which would make sense if it was in their house. This is out the wilderness.
Are they cheating? I'm not sure what to do with this guy.
Hello!!Could I translate your DiamondHunter to Chinese? 請問我能將您的插件翻譯成中文嗎?
@Aponatur
I can try and add support I know nothing about mySQL, but I could learn and try and add it. It might take a while for me to add it though.
How about to add support for a mysql database? So it would be easier to check how many diamonds a player could have found. :)
@Jwoolley
Thanks, thats the same problem I'm facing.
@Medule
To use /dh you need permission node dh.reload. To use /dh reload and /dh off you also require dh.reload. So I'm not sure why that is.
I tried deoping myself on my test server and did /dh and it worked fine. I also didn't have dh.reload. So I'm not to sure what's happening there.
I think there is something wrong with permissions though, which I need to look in to more. I wasn't oped and had no dh permissions and I was able to do /dh, /dh reload and /dh off but I didn't have permission to /dh on.
I will look in to it and try and fix it and get a new version uploaded.
./dh on won't work, it says I've no permission for it. However, when I OP myself it works. I don't understand, /dh reload and /dh off works though, can you explain why?
Uploaded a new DiamondHunter
Fixes the log storing wrong information Added dh.exempt Added /dh off Added /dh on
File will be available once Bukkit has accepted it.
Its all good. I say just take your time and do it right. :)
@Switorik
Sorry it's taking so long to get a new version uploaded. I managed to stop notices showing with the permission node. I did it within 20 minutes. So I decided to try and add less chat spam by showing how many was broken. I managed to break the whole plugin and I got to try and fix it.
As soon as I have fixed it I will upload the new version.
@Switorik
Yeah I can add that for you. I will try and add it now and get it uploaded by the end of the day for you
Can you add a permission to be exempt when mining? For example, I would give admins dh.exempt so when they mine diamonds, they wouldn't show up.
I like this plugin, its a great idea and thanks for making it!
wow!