Move nbt ops to nbt package (#1651)

Fixes #1649

Signed-off-by: liach <liach@users.noreply.github.com>

Co-authored-by: liach <liach@users.noreply.github.com>
This commit is contained in:
liach 2020-08-03 06:39:31 -05:00 committed by GitHub
parent 52768fb916
commit 54581b9a7e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 21 additions and 4 deletions

View File

@ -1,4 +0,0 @@
CLASS net/minecraft/class_2509 net/minecraft/datafixer/NbtOps
COMMENT Used to represent a Minecraft NBT as a {@link com.mojang.datafixers.Dynamic} for DataFixerUpper.
FIELD field_11560 INSTANCE Lnet/minecraft/class_2509;
CLASS class_5320 MapBuilder

View File

@ -0,0 +1,21 @@
CLASS net/minecraft/class_2509 net/minecraft/nbt/NbtOps
COMMENT Used to handle Minecraft NBTs within {@link com.mojang.serialization.Dynamic
COMMENT dynamics} for DataFixerUpper, allowing generalized serialization logic
COMMENT shared across different type of data structures. Use {@link NbtOps#INSTANCE}
COMMENT for the ops singleton.
COMMENT
COMMENT <p>For instance, dimension data may be stored as JSON in data packs, but
COMMENT they will be transported in packets as NBT. DataFixerUpper allows
COMMENT generalizing the dimension serialization logic to prevent duplicate code,
COMMENT where the NBT ops allow the DataFixerUpper dimension serialization logic
COMMENT to interact with Minecraft NBTs.</p>
COMMENT
COMMENT @see NbtOps#INSTANCE
FIELD field_11560 INSTANCE Lnet/minecraft/class_2509;
COMMENT An singleton of the NBT dynamic ops.
COMMENT
COMMENT <p>This ops does not compress maps (replace field name to value pairs
COMMENT with an ordered list of values in serialization). In fact, since
COMMENT Minecraft NBT lists can only contain elements of the same type, this op
COMMENT cannot compress maps.</p>
CLASS class_5320 MapBuilder