ID Converter
1.2.3Convert item IDs to Material names. (Or back) Supports data values and the new 1.13 Materials!
Made in Germany with love (and beer)
This is a small program to convert numeric item IDs in (config) files to the names of the Material enums and to the new changed Materials from the 1.13 release. It will also try to convert data values to the new separated 1.13 IDs (or back). (Currently only supported if they are separated by a colon)
While this conversion should work in most cases doing this automatically is error-prone, so you should go and check if it found every ID and didn't replace too much.
In the case of an unknown ID it will replace it with UNKNOWN_<found id> and it might add a NOTE_<id>:<message> to it when an ID/Material was irreplaceably removed.
Command Line
IDConverter is runable from the command line (e.g. for servers).
The syntax is: IDConverter.jar <file/folder name>
You can either input a single file in which you want to convert it or a full folder to convert all files in it.
Optional parameters:
-rf,--replace-from
The type of ID to replace from. Possible values: numeric, legacy (pre 1.13), flattening
Default: numeric
-rt,--replace-to
The type of ID to replace to. Possible values: numeric, legacy (pre 1.13), flattening
Default: flattening
-r,--regex <regex>
Regex for matching the ID string. Needs to have 3 groups. (One before, one the ID and the third the stuff after the ID)
Default: depending on replace-from
-d,--depth <amount>
Amount of sub folders that should be searched though.
Default: 1
-f,--file-match <regex>
Files need to match this regex for the tool to replace stuff inside them
Default: \w+\.yml
-l,--lowercase true/false
Should the material name be lowercase?
Default: true
GUI
When started directly it will open a GUI where you can select all the settings.
As a library
You can also use IDConverter as a library. The easiest is probably to just shade in the IdMappings class and use the IdMappings#get(IdType,String) method to get the Mapping for a certain string by its type.
Maven repository:
<repository>
<id>minebench-repo</id>
<url>https://repo.minebench.de/</url>
</repository>
Maven dependency:
<dependency>
<groupId>de.themoep.idconverter</groupId>
<artifactId>mappings</artifactId>
<version>1.2-SNAPSHOT</version>
</dependency>
Example
example: 1:1
another: 3
would convert to
example: granite
another: grass
with the default settings.
ToDo
Contact me if you need any of these:
- Plugin
- Export mappings to file (csv)
- Import mappings from file
- Configurable data separator
- Progress bar
- Preset for replacement target strings (e.g. to replace a number to Material.ID)
Links
Source: https://github.com/Phoenix616/IDConverter/
Dev-builds: https://ci.minebench.de/job/IDConverter/
License: GPLv3
Donations
If this tool has helped you I would really appreciate it if you bought me a beer!
E.g. via Patreon or Paypal or a crypto coin:
Ðoge: D7G4Svo7GTNHpuhjwUBj2k7qANnZHwYD4p
BTC: 1EXMFRknc7kLwCmM1zf5LXNnPD4ihVCEhQ
Other Resources
This resource is distributed without any warranty or liability by the author.
Similar projects
Plugin →Let Me Despawn
Improves performance by tweaking mob despawn rules. Say bye to pesky unintentional persistent mobs.
25MSueta
JourneyMap
Real-time map used for mapping in-game or your browser as you explore.
14.7MSueta
Emotecraft
Create your own emotes in Minecraft.
7.5MSueta
Simple Tpa
A simple tpa plugin which sends requests
5.4MSueta
Common Network
Forge and Fabric Unified Networking Solution
3.9MSueta
Set Home
A lightweight plugin for players to set their homes.
3.8MSueta