From 00d0a534e599772623d0800c04f720743c7e96e4 Mon Sep 17 00:00:00 2001 From: kross <135918757+krossgg@users.noreply.github.com> Date: Sun, 13 Oct 2024 17:46:11 -0400 Subject: [PATCH] Serialization fixes --- .../api/recipe/ingredient/FluidContainerIngredient.java | 6 ++++++ .../gtceu/common/recipe/condition/DimensionCondition.java | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/gregtechceu/gtceu/api/recipe/ingredient/FluidContainerIngredient.java b/src/main/java/com/gregtechceu/gtceu/api/recipe/ingredient/FluidContainerIngredient.java index d7f94a70a3..ffcc6c3a56 100644 --- a/src/main/java/com/gregtechceu/gtceu/api/recipe/ingredient/FluidContainerIngredient.java +++ b/src/main/java/com/gregtechceu/gtceu/api/recipe/ingredient/FluidContainerIngredient.java @@ -120,6 +120,12 @@ public boolean extractFrom(IFluidTransfer handler, boolean simulate) { return false; } + @Override + @NotNull + public IIngredientSerializer getSerializer() { + return SERIALIZER; + } + public static FluidContainerIngredient fromJson(JsonObject json) { return SERIALIZER.parse(json); } diff --git a/src/main/java/com/gregtechceu/gtceu/common/recipe/condition/DimensionCondition.java b/src/main/java/com/gregtechceu/gtceu/common/recipe/condition/DimensionCondition.java index 31226a2f17..5dc771f9df 100644 --- a/src/main/java/com/gregtechceu/gtceu/common/recipe/condition/DimensionCondition.java +++ b/src/main/java/com/gregtechceu/gtceu/common/recipe/condition/DimensionCondition.java @@ -111,7 +111,7 @@ public JsonObject serialize() { public RecipeCondition deserialize(@NotNull JsonObject config) { super.deserialize(config); dimension = new ResourceLocation( - GsonHelper.getAsString(config, "dim", "dummy")); + GsonHelper.getAsString(config, "dimension", "dummy")); return this; }