PowerNBT
[PowerNBT]
PowerNBT moved to spigotmc.org
Powerful NBT editor for CraftBukkit 1.5 and later.
Simple NBT API (for developers).
Works with CraftBukkit, MCPC+, Cauldron, Spigot (fix to forge 1.4.7)
Features
- Browsing and editing NBT tags
- supports items, players, offline-players, entities, blocks, chunks, schematic files and all other nbt files
- save tags to file
- spawn entity with custom nbt tags
- parse mojangson string
- custom colors and unicode symbols
- supports tab-completion
- supports operations copy/paste/cut/swap
- supports variables
All commands
See: commands
Examples
- /
nbt me Inventory remove
- clear inventory
- /
nbt me Inventory = *Bob EnderItems
- get Bob's enderchest to yourself
- /
nbt @Eve remove
- remove file Eve.dat (offline player)
- /
nbt block ExtraType = "Notch"
- set skull owner
- /
nbt * Health = 1000
- set 1000 health to mob, which you select
- /
nbt item ench copy
- copy item enchantments to buffer
- /
nbt item ench paste
- paste enchantments to other item
Permissions
- powernbt.use
Bugs
- 0.8.1-0.8.2:
On command /nbt chunk = ...
invisible players and entities in new chunk.
- If you found a bug, please report me in github:
https://github.com/DPOH-VAR/PowerNBT/issues
Changelog
Version 0.8.2 beta
- added: binary opetarions: ^= , &= , |= , useful to set binary flags
- added: operation: multiplication: *=
- added: operation: spawn entity
- added: value: numbers in binary format
- added: values in mojangson format
- added: object: hand
- added: object: schematic
- added: view mode: binary
- added: silent mode for command
- added: API: read chunk
- added: API: save chunk
- added: API: parse mojangson string
- added: API: spawn entity
- fixed: support cauldron 1.7.10
- bug: invisible players after change chunk data.
- bug: on update blocks after change chunk. cauldron 1.7.10
Version 0.8.1
- added: read/write chunks
Version 0.7.3.1
- fix: work with Cauldron 1.7.2
Tutorials
- How to edit tags
- How to use Tab-Completion
- How to edit mobs into spawners
- How to edit villagers
- How to create custom potions
- How to edit fireworks (RU)
API
See API for documentation and examples
Maven dependency (since 0.7.2)
API for version 0.7.2 and later
Warning
If you add a tag, which is not expected by the client, it may be crashed. Be careful!
Helpful links, about NBT format:
- http://www.minecraftwiki.net/wiki/NBT_format
- http://www.minecraftwiki.net/wiki/Player.dat_Format
- http://www.minecraftwiki.net/wiki/Chunk_format
Github | Maven | Javadoc |
@Frontrider
PowerNBT can not spawn mobs by itself
How do i stack mobs on each other whitout spawners?
@t3f
1) use scripting plugin + PowerNBT API
VarScript
copy nbt tag to variable:
/> ME TARGETBLOCK NBT %tag
edit nbt tag with varscript:
/> @tag.Items:{"Count" 10 MPUT}
or edit nbt tag with groovy:
g>> for (item in tag.Items) item.Count = 10 as int
paste tag back to block:
/> ME TARGETBLOCK @tag SETNBT
2) maybe I'll add it in the next version
someting like this:
/nbt block Items { Count = 10 int, data + 1 }
Any way to set a common tag used by multiple elements in an array?
Ex: on a chest, can I do something like:
"/nbt block Items[*].Count = 10 int"
or
"/nbt item CustomPotionEffects[*].Duration = 5000 int" ?
Thanks!
@iWareWolf
Yes.
I think that Dimension is world ID
But you need a last version of plugin (0.5.4 or later)
How can I edit which dimension a player is while he is offline?
I tried:
/nbt @iWareWolf_ Dimension = 2
@sheshinjie
1: http://dev.bukkit.org/bukkit-plugins/powernbt/pages/tutorial/potions/
2: http://dev.bukkit.org/bukkit-plugins/powernbt/pages/tutorial/mobspawner_potions/
How to edit potion into spawners??
@excavator5
See this http://dev.bukkit.org/bukkit-plugins/powernbt/pages/tutorial/villagers/
Offers.Recipes[..].buy - first item
Offers.Recipes[..].buyB - second item
How do you edit the secondary item to trade for buy. Example, Set up: 5 Iron Blocks and 2 Iron Ingots for a Diamond ChestPlate. 47 Iron for Diamond ChestPlate. I cannot figure out how to get the 2 Ingots put in. Help?
@repthutek
Good idea
I think I will add an option in the config file to disable reading UUID tags.
Would it be a good practice to remove UUID's from mobs when dealing with spawners? In your stacked mob spawner tutorial, I see that you remove them from each mob before having them spawned, but I'm not really sure what doing so means, or if it would be beneficial to do so by default even for non-stacked spawners.
@t3f
You found a bug
Thanks
I will fix it asap
UPD:
fixed in version 0.5.4
I seem to get {IO error} when doing any modification operation to an offline players NBT data, for example: /nbt @OtherUser Pos[0] = -800; the NBT .dat files in world/players/OtherUser.dat are then truncated and zero byte. Is there a workaround?
Thanks a bunch for this! Only need the api, but it's great!
@awesomestmason
You can set Invulnerable = true
or set large health and maxhealth:
Attributes[0].Base = 100000
HealF = 100000
or add potion effect to ActiveEffects (see http://www.minecraftwiki.net/wiki/Chunk_format )
@DoubleZ
It seems that you can not change owner of the wolf
Because you can't use nbt tags to rewrite his AI
@DPOHVAR
I didn't realise that it's so easy to save and edit files, that's totally enough :-)
hi, is it possible to change the owner of tamed wolf?
I have tried once, I edited Owner tag, but the wolf didn't follow its new owner.
How might I add potion effects to a mob? I want to add health boost to a cow, so it can't die.
@repthutek
1)
set DropItem = false
falling block should disappear if they fall to the slab or torch
2)
Particles is not entities => you can not spawn particles with PowerNBT