ToughAnvils
ToughAnvils
ToughAnvils allows anyone with the right permissions to mark an anvil as 'indestructible'. The anvil may still be broken by a pickaxe, but normal usage will not wear it out. This plugin was created to fill a request, and as it turns out, it's quite difficult to accomplish due to a lack of Bukkit API for locating the actual Anvil block involved in an Anvil Inventory action. ToughAnvils currently works with all 1.7.2-1.7.4 and will be backported to the 1.6.x series soon.
Commands
- /toughanvils [set|unset]
Use 'set' or 'unset' to make an anvil indestructible, or destructible, respectively. after entering the command you will be prompted to hit the anvil you wish to select, once you've done this the change will take effect immediately.
Permissions
- toughanvils.command - required to have any access to the /toughanvils command
- toughanvils.command.set - allows usage of /toughanvils set
- toughanvils.command .unset- allows usage of /toughanvils unset
Developers
Other Developers may wish to hook into ToughAnvils solely for it's Anvil-Locating functionality, ToughAnvils provides a public method directly on the plugin instance:
public Location getAnvilLocation(AnvilInventory inv) { ToughAnvils toughAnvilsPlugin = (ToughAnvils) getPluginManager().getPlugin("ToughAnvils"); if (toughAnvilsPlugin != null && toughAnvilsPlugin.isEnabled()) { return toughAnvilsPlugin.getAnvilLocation(inv); } return null; }
Source Code
This plugin is open source, and is available on GitHub.
please update. this is very sweg plugin that many people use
Update please. Doesn't work for 1.8.3.
Does anyone know if this conflicts with mcMMO in any way? My anvils now take longer to break, but do ultimately break. I am using the latest dev build #4.
Just tested and it works great, Thanks again!
@metalhedd
Thank you very much. Ill test it out again and report back.
I have Inns and Blacksmiths on my server in towns and this plugin is vital to that, I was going to put in a request to my developer and ran into this, so I'm excited not to load his plate :P
By the way, do you have skype? Wanted to throw a question at you privately.
@InsomniaCraft
I could be wrong, but after many tests, I think this plugin makes all anvils indestructible regardless of whether or not you've set them that way.
On a non op player with no permissions, I place an anvil in a remote location, I used a very damaged anvil to see up the process, if thats relevant, and tried repairing diamond swords using 200 levels I gave myself. On the first repair, it appears that the anvil repairs itself instantly, by looking at the anvils animation.
@InsomniaCraft
I added a link to development builds at the bottom of the page here. Make sure to only grab 'ToughAnvils' (the first module listed on that page) not the -API or -parent or others. they're just part of the build process.
Im unable to compile right now due to lack of software, but Would love to get this plugin running asap, Bukkit can sometimes take weeks to approve stuff, do you think you can upload the Jar to your github?
@CommodoreAlpha
It stores the locations in a yaml file and loads it on server startup. This plugin is similar to those other plugins in that it also just repairs the anvil. But it does it immediately after each use. It also correctly tracks the locations of indestructible anvils even if they fall to a new location.
How does the plugin remember which anvils are supposed to be "unbreaking", and which are supposed to be normal? Through some sort of database, I take it?
Very nice implementation for a plugin though, as most other anvil-fix plugins just fix anvils, rather than making them indestructible.
@keenpizzaboy
Queued for approval by DBO staff.
Wheres de download :>?
Finally! Been looking for this. Awaiting download :)