Most latest information is also on
My Website:
http://blog.exz.me/wailanbt/
MCF:
http://www.minecraftforum.net/forums/mapping-and-modding/minecraft-mods/wip-mods/2220567
Download:
http://www.curse.com/mc-mods/minecraft/224417-waila-nbt
But feel free to post here. I'll read and update this thread too.
Description
Waila NBT is a mod to show player defined specific
NBT info on Waila HUD.
Waila NBT is a Client-Side addon for
Waila. And
In-Game NBTEdit (
1.7.10 version)is needed to look up NBT data structure.
Examples (with config files)
Download .json file and put in config\WailaNBT folder and its ready to use.
Please share your config!
Botania (Holding Forestry Wand)
https://raw.githubusercontent.com/exzhawk/wailanbt/master/eclipse/config/WailaNBT/botania.json
Blood magic (Holding Divination Sigil)
https://raw.githubusercontent.com/exzhawk/wailanbt/master/eclipse/config/WailaNBT/bloodmagic.json
BuildCraft (Holding BC Wrench)
https://github.com/exzhawk/wailanbt/raw/master/eclipse/config/WailaNBT/buildcraft.json
Tutorial
Blood Magic by WayofTime and
Botania by Vazkii are used as examples for tutorial.
First, drop the jar file into mods and start game.
A configuration folder as well as an empty file “default.json” will be generated in your config folder. The mod is useless until you put right config in it.
The config file is in
JSON format looks like this:
Code:
{
"Holding Item Name": {
"Tile Entity ID 1": {
"Tag Name 1": "Display Name 1",
"Tag Name 2>>>Tag Name 3": "Display Name 2"
},
"Tile Entity ID X": {
},
"Holding Item Name X": {}
}
}
This configuration means, when player holding an item named “Holding Item Name”, and point cursor at a
Tile Entity with ID “Tile Entity ID 1″, “Value of Tag Name” will be shown, and “Display Name 1″is the name that will represent “Value of Tag Name” in Waila HUD.
“Tag Name 2>>>Tag Name 3″ means display the value of “Tag Name 3″ in the NBT Tag Compound named “Tag Name 2″. That’s somehow similar to a sub folder. Use “>>>” to separate to name if “Tag Name 3″ is inside “Tag Name 2″. “>>>” should only be used under this sub folder condition.
“Holding Item Name”, “Tile Entity ID 1″ and “Tag Name 1″ support regular expression, so some special characters like “|”(pipe) need a “\”(backslash) before it. e.g: “BuildCraft|Transport” must be written as “BuildCraft\|Transport”.
Let’s take a living example.
Blood Altar is a basic block of Blood Magic. It can store “Life Essence” and transmute items.
When pointing at it, run command “/nbtedit”
And here is what the tool(Divination Sigil) from blood magic says.
Now we know the ID of this block is “
containerAltar“, and we guess that the “
Amount” is the “Current Essence” and “
capacity” is “Capacity”.
The target is, when holding the Divination Sigil, we can directly read the “Current Essence” and “Capacity” from the Waila HUD rather than a right click.
Hold the Divination Sigil and run command “/wnn” (stand for Waila NBT Name). The identify name “
AWWayofTime:divinationSigil” of it will be shown in chat window.
So we write following content to default.json. (Or if you wanna keep them in order, create a “bloodmagic.json” and write in it instead.)
Code:
{
"AWWayofTime:divinationSigil": {
"containerAltar": {
"Amount": "Current Essence",
"capacity": "Capacity"
}
}
}
After saving the config file. Run command “/wnr” (stand for Waila NBT Reload) to reload configuration.
Then hold the Divination Sigil and point at the Blood Altar.
It works!
Let’s try another. Daybloom.
Run command “/nbtedit” first.
ID is “botania:specialFlower”, and what useful data “mana” is under a NBTTagCompound named “subTileCmp”.
Save following content to “botania.json” in folder “config/WailaNBT”. (Where the default.json located.)
Code:
{
".*": {
"botania:specialFlower": {
"subTileCmp>>>mana": "Mana"
}
}
}
“.*” is an regular expression matches all string. Note it also matches hand without holding anything. Because holding nothing equals holding an item named “”(empty string).
And don’t forget run command “/wnr” to reload configuration.
Now point at Daybloom and it should work.
Notice
This mod is over powered and may destroy experience in survival mode. It’s generally written for testing purpose. Don’t use it on server since it may be considered as cheating.
Holding nothing equals holding an item named “”(empty string).
If display name is not provided (like “Amount”:””), the tag name(“Amount”) will be used.
Postfix b means that number is “byte” type, etc. And quotation marks indicate that the value is “string” type.
Planning Feature
Support for Entities.
Support for item tooltips.
More complex match method.
More debug info.
Better handle conflict json object.
postfix “f” “d”
Thanks
Prof Mobius for bring us Waila.
Pahimar for teaching me basic modding.
ViKaleidoscope for Simplified Chinese localization and config files.
Fixided for tutorial editing advice.