Two new exception classes and a bunch of legacy names (#2309)

* Two new exception classes and a bunch of legacy names

Done in a way to avoid/minimize conflict with #2300

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

* Update mappings/net/minecraft/client/render/model/json/JsonUnbakedModel.mapping

❤️ yanis

Co-authored-by: YanisBft <doublecraft.official@gmail.com>

Co-authored-by: liach <liach@users.noreply.github.com>
Co-authored-by: YanisBft <doublecraft.official@gmail.com>
This commit is contained in:
liach 2021-04-11 19:09:01 +07:00 committed by GitHub
parent 339a846b43
commit 54ee32397a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 36 additions and 9 deletions

View File

@ -1,6 +1,9 @@
CLASS net/minecraft/class_793 net/minecraft/client/render/model/json/JsonUnbakedModel
FIELD field_21857 guiLight Lnet/minecraft/class_793$class_4751;
FIELD field_32792 PARTICLE_KEY Ljava/lang/String;
FIELD field_32793 TEXTURE_REFERENCE_INITIAL C
COMMENT The initial character ({@value}) of a texture reference in JSON; used to
COMMENT distinguish texture references from other references.
FIELD field_4244 ambientOcclusion Z
FIELD field_4245 elements Ljava/util/List;
FIELD field_4247 parentId Lnet/minecraft/class_2960;
@ -57,7 +60,10 @@ CLASS net/minecraft/class_793 net/minecraft/client/render/model/json/JsonUnbaked
ARG 3 side
ARG 4 settings
ARG 5 id
METHOD method_35789 needsResolution ()Z
CLASS class_795 Deserializer
FIELD field_32794 DEFAULT_AMBIENT_OCCLUSION Z
COMMENT The default value for ambient occlusion if unspecified in JSON; is {@value}.
METHOD deserialize (Lcom/google/gson/JsonElement;Ljava/lang/reflect/Type;Lcom/google/gson/JsonDeserializationContext;)Ljava/lang/Object;
ARG 1 element
ARG 2 unused
@ -65,17 +71,17 @@ CLASS net/minecraft/class_793 net/minecraft/client/render/model/json/JsonUnbaked
METHOD method_24079 resolveReference (Lnet/minecraft/class_2960;Ljava/lang/String;)Lcom/mojang/datafixers/util/Either;
ARG 0 id
ARG 1 name
METHOD method_3448 deserializeTextures (Lcom/google/gson/JsonObject;)Ljava/util/Map;
METHOD method_3448 texturesFromJson (Lcom/google/gson/JsonObject;)Ljava/util/Map;
ARG 1 object
METHOD method_3449 deserializeElements (Lcom/google/gson/JsonDeserializationContext;Lcom/google/gson/JsonObject;)Ljava/util/List;
METHOD method_3449 elementsFromJson (Lcom/google/gson/JsonDeserializationContext;Lcom/google/gson/JsonObject;)Ljava/util/List;
ARG 1 context
ARG 2 json
METHOD method_3450 deserializeParent (Lcom/google/gson/JsonObject;)Ljava/lang/String;
METHOD method_3450 parentFromJson (Lcom/google/gson/JsonObject;)Ljava/lang/String;
ARG 1 json
METHOD method_3452 deserializeOverrides (Lcom/google/gson/JsonDeserializationContext;Lcom/google/gson/JsonObject;)Ljava/util/List;
METHOD method_3452 overridesFromJson (Lcom/google/gson/JsonDeserializationContext;Lcom/google/gson/JsonObject;)Ljava/util/List;
ARG 1 context
ARG 2 object
METHOD method_3453 deserializeAmbientOcclusion (Lcom/google/gson/JsonObject;)Z
METHOD method_3453 ambientOcclusionFromJson (Lcom/google/gson/JsonObject;)Z
ARG 1 json
CLASS class_4751 GuiLight
FIELD field_21858 ITEM Lnet/minecraft/class_793$class_4751;
@ -86,5 +92,9 @@ CLASS net/minecraft/class_793 net/minecraft/client/render/model/json/JsonUnbaked
METHOD <init> (Ljava/lang/String;ILjava/lang/String;)V
ARG 3 name
METHOD method_24299 isSide ()Z
METHOD method_24300 deserialize (Ljava/lang/String;)Lnet/minecraft/class_793$class_4751;
METHOD method_24300 byName (Ljava/lang/String;)Lnet/minecraft/class_793$class_4751;
ARG 0 value
CLASS class_6246 UncheckedModelException
COMMENT An unused unchecked exception. Probably related to unbaked models.
METHOD <init> (Ljava/lang/String;)V
ARG 1 message

View File

@ -11,10 +11,25 @@ CLASS net/minecraft/class_790 net/minecraft/client/render/model/json/ModelVarian
METHOD method_3421 getMultipartModel ()Lnet/minecraft/class_816;
METHOD method_3422 hasMultipartModel ()Z
METHOD method_3423 getVariantMap ()Ljava/util/Map;
METHOD method_3424 deserialize (Lnet/minecraft/class_790$class_791;Ljava/io/Reader;)Lnet/minecraft/class_790;
METHOD method_3424 fromJson (Lnet/minecraft/class_790$class_791;Ljava/io/Reader;)Lnet/minecraft/class_790;
ARG 0 context
ARG 1 reader
METHOD method_35790 containsVariant (Ljava/lang/String;)Z
COMMENT Checks if there's a variant under the {@code key} in this map.
COMMENT
COMMENT @return {@code true} if the {@code key} has a variant, {@code false} otherwise
ARG 1 key
COMMENT the variant's key
METHOD method_35791 getAllModels ()Ljava/util/Set;
METHOD method_35792 getVariant (Ljava/lang/String;)Lnet/minecraft/class_807;
COMMENT Finds and returns the definition of the variant under the {@code key}. If the
COMMENT {@code key} does not {@linkplain #containsVariant(String) exist}, this throws
COMMENT an exception.
COMMENT
COMMENT @return the variant definition
COMMENT @throws VariantAbsentException if no variant with the given {@code key} exists
ARG 1 key
COMMENT the variant's key
CLASS class_791 DeserializationContext
FIELD field_4242 stateFactory Lnet/minecraft/class_2689;
FIELD field_4243 gson Lcom/google/gson/Gson;
@ -26,9 +41,11 @@ CLASS net/minecraft/class_790 net/minecraft/client/render/model/json/ModelVarian
ARG 1 functionJson
ARG 2 unused
ARG 3 context
METHOD method_3427 deserializeMultipart (Lcom/google/gson/JsonDeserializationContext;Lcom/google/gson/JsonObject;)Lnet/minecraft/class_816;
METHOD method_3427 multipartFromJson (Lcom/google/gson/JsonDeserializationContext;Lcom/google/gson/JsonObject;)Lnet/minecraft/class_816;
ARG 1 context
ARG 2 object
METHOD method_3429 deserializeVariants (Lcom/google/gson/JsonDeserializationContext;Lcom/google/gson/JsonObject;)Ljava/util/Map;
METHOD method_3429 variantsFromJson (Lcom/google/gson/JsonDeserializationContext;Lcom/google/gson/JsonObject;)Ljava/util/Map;
ARG 1 context
ARG 2 object
CLASS class_6247 VariantAbsentException
COMMENT An unchecked exception indicating a variant is not found with a string key.