Skip to content
This repository has been archived by the owner on Sep 19, 2024. It is now read-only.

Commit

Permalink
ExprNbtCompound - add more docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ShaneBeee committed Nov 2, 2023
1 parent 5ed19f9 commit 6793fec
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,17 @@
"\n'nbt compound' from an item will be the original. This will return the 'tag' portion of an items full NBT.",
"Modifying this will modify the original item.",
"\nNBT from a file will need to be saved manually using",
"the 'NBT - Save File effect'. If the file does not yet exist, a new file will be created."})
"the 'NBT - Save File effect'. If the file does not yet exist, a new file will be created.",
"\nNBT Compounds can be added to each other, thus merging them. See Examples."})
@Examples({"set {_n} to nbt compound of player's tool",
"set {_nbt} to nbt compound of target entity",
"set {_n} to nbt compound of \"{id:\"\"minecraft:diamond_sword\"\",tag:{Damage:0,Enchantments:[{id:\"\"minecraft:sharpness\"\",lvl:3s}]},Count:1b}\"",
"set {_nbt} to nbt compound of file \"world/playerdata/some-uuid.dat\"",
"set {_n} to nbt compound of chunk at player"})
"set {_n} to nbt compound of chunk at player",
"",
"add nbt from \"{NoAI:1}\" to nbt of last spawned entity",
"add nbt from \"{NoGravity:1}\" to nbt of {_entity}",
"add nbt from \"{custom:{points:1}}\" to nbt of player"})
@Since("1.6.0")
public class ExprNbtCompound extends PropertyExpression<Object, NBTCompound> {

Expand Down

0 comments on commit 6793fec

Please sign in to comment.