mirror of
https://github.com/FabricMC/fabric.git
synced 2025-04-08 21:14:41 -04:00
1.20-pre3
- Only mapping updates.
This commit is contained in:
parent
0bf4e42290
commit
63e9e1806d
6 changed files with 7 additions and 7 deletions
fabric-recipe-api-v1/src
main/java/net/fabricmc/fabric
impl/recipe/ingredient/builtin
mixin/recipe/ingredient
testmod/java/net/fabricmc/fabric/test/recipe/ingredient
|
@ -74,7 +74,7 @@ abstract class CombinedIngredient implements CustomIngredient {
|
|||
Ingredient[] ingredients = new Ingredient[values.size()];
|
||||
|
||||
for (int i = 0; i < values.size(); i++) {
|
||||
ingredients[i] = Ingredient.method_52177(values.get(i));
|
||||
ingredients[i] = Ingredient.fromJson(values.get(i));
|
||||
}
|
||||
|
||||
return factory.apply(ingredients);
|
||||
|
|
|
@ -72,8 +72,8 @@ public class DifferenceIngredient implements CustomIngredient {
|
|||
|
||||
@Override
|
||||
public DifferenceIngredient read(JsonObject json) {
|
||||
Ingredient base = Ingredient.method_52177(json.get("base"));
|
||||
Ingredient subtracted = Ingredient.method_52177(json.get("subtracted"));
|
||||
Ingredient base = Ingredient.fromJson(json.get("base"));
|
||||
Ingredient subtracted = Ingredient.fromJson(json.get("subtracted"));
|
||||
return new DifferenceIngredient(base, subtracted);
|
||||
}
|
||||
|
||||
|
|
|
@ -109,7 +109,7 @@ public class NbtIngredient implements CustomIngredient {
|
|||
|
||||
@Override
|
||||
public NbtIngredient read(JsonObject json) {
|
||||
Ingredient base = Ingredient.method_52177(json.get("base"));
|
||||
Ingredient base = Ingredient.fromJson(json.get("base"));
|
||||
NbtCompound nbt = readNbt(json.get("nbt"));
|
||||
boolean strict = JsonHelper.getBoolean(json, "strict", false);
|
||||
return new NbtIngredient(base, nbt, strict);
|
||||
|
|
|
@ -44,7 +44,7 @@ public class IngredientMixin implements FabricIngredient {
|
|||
target = "net/minecraft/recipe/Ingredient.entryFromJson (Lcom/google/gson/JsonObject;Z)Lnet/minecraft/recipe/Ingredient$Entry;",
|
||||
ordinal = 0
|
||||
),
|
||||
method = "fromJson",
|
||||
method = "fromJson(Lcom/google/gson/JsonElement;Z)Lnet/minecraft/recipe/Ingredient;",
|
||||
cancellable = true
|
||||
)
|
||||
private static void injectFromJson(JsonElement json, boolean requireNotEmpty, CallbackInfoReturnable<Ingredient> cir) {
|
||||
|
|
|
@ -49,7 +49,7 @@ public class SerializationTests {
|
|||
JsonElement json = JsonParser.parseString(ingredientJson);
|
||||
|
||||
try {
|
||||
Ingredient.method_52177(json);
|
||||
Ingredient.fromJson(json);
|
||||
throw new GameTestException("Using a custom ingredient inside an array ingredient should have failed.");
|
||||
} catch (IllegalArgumentException e) {
|
||||
context.complete();
|
||||
|
|
|
@ -3,7 +3,7 @@ org.gradle.parallel=true
|
|||
fabric.loom.multiProjectOptimisation=true
|
||||
|
||||
version=0.81.2
|
||||
minecraft_version=1.20-pre2
|
||||
minecraft_version=1.20-pre3
|
||||
yarn_version=+build.1
|
||||
loader_version=0.14.19
|
||||
installer_version=0.11.1
|
||||
|
|
Loading…
Add table
Reference in a new issue