Item Renamer
Tired of blocks called Sand? Want your enderpearls to say Grenade instead? Want to add extra lines of text below item names? Do all that and more with ItemRenamer. You can create your own custom item names for all items in your server, but still let users rename with an anvil. You can create your very own language pack!
Installation
- Download ProtocolLib and put it in your plugins folder
- Place ItemRenamer.jar in your plugins folder, on server start the configuration will be generated
- Test out the example config by setting your world to run the example pack, to see how it works
- Go crazy and make your own language pack
Developer Build
Development builds of this project can be acquired at the provided continuous integration server.
These builds have not been approved by the BukkitDev staff. Use them at your own risk.
Jenkins server
For developers
ItemRenamer 2.0.0 contains a fully-fledged API. Click here for more information.
Configuration
Default configuration can be found here.
Config | Default | Ranges | Description |
---|---|---|---|
autoupdate | true | [true/false] | Will remind you when a new version is available |
creativedisable | true | [true/false] | Will disable ItemRenamer while you're in creative mode |
worlds.<worldname> | Pack name | Will set this world to run the pack you put here | |
packs.<packname>.<itemid>.<data>.name | Any string | Will rename itemid:data to your string | |
packs.<packname>.<itemid>.all.name | Any string | Will rename all itemid data values to your string | |
packs.<packname>.<itemid>.other.name | Any string | Will rename all unset itemid data values to your string | |
packs.<packname>.<itemid>.<data>.name | Any string | Will add your name to itemid:data | |
packs.<packname>.<itemid>.<data>.lore | Any string | Will add your lore list to itemid:data | |
packs.<packname>.<itemid>.<first>-<last>.name | Any string | Will add your name to every itemid with a data value of the give range. | |
packs.<packname>.<itemid>.<first>-<last>.lore | Any string | Will add your lore list to every itemid with a data value of the give range. | |
packs.<packname>.<itemid>.all.lore | Any string | Will add your lore list to all itemid data values | |
packs.<packname>.<itemid>.other.lore | Any string | Will add your lore list to all unset itemid data values |
- Note: place lore in [square brackets] OR on seperate lines starting with a dash -
Player-specific packs
If you want to customize the renamer pack for a specific group of players, regardless of world, you may use the player info itempack along with the desired renamer pack. This feature requires Vault and a permission/chat plugins that supports player info.
This can be done as follows with PermissionEx:
users: Player: group: - Members options: itempack: none
Usage
It's possible to configure ItemRenamer without ever having to touch the configuration file or deal with the more complicated (but powerful) commands. Simply select an item you want to rename, and type the following:
/renamer select hand
That will select your current item's ID and durability (except for armor and tools), along with any enchantments, potion/fireworks effect, etc. Then use set name and add lore to rename the item and every other like it on the server:
/renamer set name Nameless Tool /renamer add lore Unknown Artifact
This will automatically be applied to the current world you're in. Use "renamer set pack" to apply it to a different item pack, or teleport to the world with the item pack you want to rename.
Commands
- Change whether or not to automatically check for updates:
/renamer set setting autoupdate [true|false] - Get what item pack has been assigned to a particular world:
/renamer get world [world_name] - Assign an item pack to the given world:
/renamer set world [world_name] [pack_name] - Add a new item pack:
/renamer add pack [pack_name] - Delete an item pack:
/renamer delete pack [pack_name] - Select a item pack to use for all subsequent commands:
/renamer select pack [pack_name] - Rename all items similar to the one the player currently is holding:
/renamer select hand - Deselect the current item pack, going back to manually typing it:
/renamer select none - Get the rename rule for a particular item:
/renamer get item [pack_name] [itemID] [all|other|0-32767] - Set the name of an item(s) matching a single or multiple damage values:
/renamer set name [pack_name] [itemID] [all|other|0-32767] [0-32767] [name (with spaces)] - Add a new lore line to an item(s) matching a single or multiple damage values:
/renamer add lore [pack_name] [itemID] [all|other|0-32767] [0-32767] [lore (with spaces)] - Remove all the existing lores for a particular set of items:
/renamer delete lore [pack_name] [itemID] [all|other|0-32767] [0-32767] - Add a new enchantment to a set of items: /renamer add enchantment [pack_name] [itemID] [all|other|0-32767] [0-32767] [enchantment_name] [level]
- Remove an existing enchantment for a set of items: /renamer remove enchantment [pack_name] [itemID] [all|other|0-32767] [0-32767] [enchantment_name] [level]
- Reload configuration:
/renamer reload - Save configuration now instead of during server shutdown:
/renamer save
All commands default to OP, but also have permissions.
Modify enchantments
It is also possible to add or remove existing enchantments to any given item. The easiest method is to mark the item you want to modify in your hotbar, and type the following command:
/renamer select hand /renamer add enchantment NO_ATTRIBUTES 1
Every vanilla enchantment is supported:
- Bow: POWER, PUNCH, INFINITY, FLAME
- Weapon: SHARPNESS, BANE_OF_ARTHROPODS, SMITE, FIRE_ASPECT, KNOCKBACK, LOOTING, UNBREAKING
- Tool: FORTUNE, EFFICIENCY, UNBREAKING, SILK_TOUCH
- Armor: RESPIRATION, PROTECTION, BLAST_PROTECTION, FEATHER_FALLING, FIRE_PROTECTION, PROJECTILE_PROTECTION, THORNS, AQUA_AFFINITY
There's also three custom enchantments:
- GLOW 1: Preserve the enchantment glow with no visible enchantment name
- NO_ATTRIBUTES 1: Remove all the attribute lines introduced in 1.6.1 and 1.6.2.
- NO_DURABILITY 0: Remove any visible durability on the item. Switch out 0 with any other number to force a durability value.
Permissions
itemrenamer.config.get — read-only access to configs
itemrenamer.config.set — can edit configs or reload from disk
itemrenamer.update — gets a notification when update is ready, and can use update command
Notes
- Join us on irc at: irc://esper.net/ItemRenamer
- Items in the creative menu are only client-side, and thus cannot be renamed by this plugin. But creative players will see their items renamed in the main inventory bar.
- This plugin doesn't actually edit any items, they just appear renamed .. if you were to suddenly stop using this plugin all items should go back to normal
- If a player renames an item in an anvil, that name should take precedence over the ItemRenamer one
- When setting lore in game make sure to wrap the text in square brackets, each line separated by a comma, and enclosed in quotes if it contains special characters
Sourcecode
Access the source code via GitHub:
https://github.com/meiskam/ItemRenamer
Please please PLEASE fix the bug Nisovin just posted about names not working in villager trade windows.
Another bug: villager trade options don't get renamed.
@sjoerdtim
I would also REALLY like to see multiworld, support on this. It's exactly what I've been looking for!
There is a bug with the way this works. If a player is in creative mode, clicking on, or even mousing over (maybe even just opening the inventory?), an item in the inventory will forcibly update the item to have the new name on the server side. The server trusts players in creative mode, and since the client thinks the item is renamed, the server will believe it.
This is easily reproduced. Set up a renamed item, place that item on your hotbar, enter creative mode, mouse over the item, shut down the server, disable ItemRenamer, start the server, join and see that the item is still renamed.
The only way I can think of to fix this is to disable the renaming when a player is in creative mode. You would also have to update the player inventory when switching game modes.
Could we use this to change item damage as well?
TODO / Known bugs
I'd like to see per world suppor ^.^
I'm hosting 2 servers at one IP and i only want them to be renamed in one of my worlds.
@deadjaw
This is happening to me aswell
I'm having a few issues. When I try to name one of the renamed items at an anvil, it doesn't use the name I want it set to with the anvil, it just reverts back to the name I set with the plugin. When I create a book and name it, it goes back to the name I have set it to in the config, same as the first issue. I can't seem to use the new enchanted books you get from your inventory in creative, or when I try to make them myself. I'm currently up to date with ProtocolLib(Using the latest snapshot) and With ItemRenamer. The other plugins I have installed are WorldBorder, WorldEdit, And WeatherMan.
Maybe it's something on my end, but i'm letting you know just to be sure.
Thanks.
@meiskam
Thats fine :)
@SuperMinecraftBrosMC
I appreciate your enthusiasm, but the reason I didn't release that GitHub commit is because it didn't work yet. I've now released a version (1.2.0016) that works with both CB RB 1.4.5-1.0 and 1.4.6-dev. Make sure you're using ProtocolLib version 1.8.4 or higher.
PS, I'm going to delete your post so people don't download a broken version.
@SuperMinecraftBrosMC
Is this for 1.4.6 or 1.4.5_1.0? Beacuse it doesn't work with RB 1.4.5_1.0.
http://pastebin.com/BKSi0xss
Confirmed broken in the new Bukkit update.
Need update please!!
Can not be used on CB145-R1.0.... But works on CB145-R0.2.
@gustebeast
Well it does work on 1.4.5 depending on what build your using.
Since Bukkit released a few new dev builds that needs plugin devs to fix. Meiskam is on vacation right now and will be updated soon enough. For the time being you can go back to a r0.2 Craftbukkit build.
Doesnt work on 1.4.5
[SEVERE] Could not load 'plugins/ItemRenamer.jar' in folder 'plugins'
org.bukkit.plugin.InvalidPluginException java.lang.NoClassDefFoundError net/minecraft/server/NBTBase
at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:154)
at org.bukkit.plugin.SimplePluginManager.loadPlugin(SimplePluginManager.java:305)
at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:230)
at org.bukkit.craftbukkit.v1_4_5.CraftServer.loadPlugins(CraftServer.java:261)
at org.bukkit.craftbukkit.v1_4_5.CraftServer.<init>(CraftServer.java:239)
at net.minecraft.server.v1_4_5.ServerConfigurationManagerAbstract.<init>(ServerConfigurationManagerAbstract.java:52)
at net.minecraft.server.v1_4_5.ServerConfigurationManager.<init>(SourceFile:11)
at net.minecraft.server.v1_4_5.DedicatedServer.init(DedicatedServer.java:111)
at net.minecraft.server.v1_4_5.MinecraftServer.run(MinecraftServer.java:402)
at net.minecraft.server.v1_4_5.ThreadServerApplication.run(SourceFile:856)
Caused by: java.lang.NoClassDefFoundError net/minecraft/server/NBTBase
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:143)
... 9 more
Caused by: java.lang.ClassNotFoundException net.minecraft.server.NBTBase
at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:34)
at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:29)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
... 12 more
@silentdojo
ty
Can you add an option to rename 1 item in your hand?
@GioboiMC
It's easy: while u set a name /ItemRenamer config set pack.354.0.name Jaffa Cake
Instead of the 0 after the itemid use all.
/ItemRenamer config set pack.354.all.name Jaffa Cake
Is it possible for you to add way for items like axes and pickaxes to retain their special names even when used (because they change damage value)
Is it possible to have many names for one item?
It's possible to have many item names using damage values, say 331:0 is paper, 331:1 is newspaper, etc.
But that's not possible with tools or armor or anything affected by damage values.