public class SpecialRecipeSerializer<T extends Recipe<?>> extends Object implements RecipeSerializer<T>
Modifier and Type | Field and Description |
---|---|
private Function<Identifier,T> |
id |
ARMOR_DYE, BANNER_DUPLICATE, BLASTING, BOOK_CLONING, CAMPFIRE_COOKING, FIREWORK_ROCKET, FIREWORK_STAR, FIREWORK_STAR_FADE, MAP_CLONING, MAP_EXTENDING, REPAIR_ITEM, SHAPED, SHAPELESS, SHIELD_DECORATION, SHULKER_BOX, SMELTING, SMITHING, SMOKING, STONECUTTING, SUSPICIOUS_STEW, TIPPED_ARROW
Constructor and Description |
---|
SpecialRecipeSerializer(Function<Identifier,T> function) |
Modifier and Type | Method and Description |
---|---|
T |
read(Identifier id,
JsonObject json) |
T |
read(Identifier id,
PacketByteBuf buf) |
void |
write(PacketByteBuf buf,
T recipe) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
register
private final Function<Identifier,T extends Recipe<?>> id
public SpecialRecipeSerializer(Function<Identifier,T> function)
public T read(Identifier id, JsonObject json)
read
in interface RecipeSerializer<T extends Recipe<?>>
public T read(Identifier id, PacketByteBuf buf)
read
in interface RecipeSerializer<T extends Recipe<?>>
public void write(PacketByteBuf buf, T recipe)
write
in interface RecipeSerializer<T extends Recipe<?>>