mojira.dev
MC-237059

Invalid texture deserialization

This bugs affects the latest snapshot (21w37a). From decompiled MC code using Fabric mappings:

public Transformation deserialize(JsonElement jsonElement, Type type, JsonDeserializationContext jsonDeserializationContext) throws JsonParseException {
            JsonObject jsonObject = jsonElement.getAsJsonObject();
            Vec3f vec3f = this.parseVector3f(jsonObject, "rotation", DEFAULT_ROTATION);
            Vec3f vec3f2 = this.parseVector3f(jsonObject, "translation", DEFAULT_TRANSLATION);
            vec3f2.scale(0.0625F);
            vec3f2.clamp(-5.0F, 5.0F);
            Vec3f vec3f3 = this.parseVector3f(jsonObject, "scale", DEFAULT_SCALE);
            vec3f3.clamp(-4.0F, 4.0F);
            return new Transformation(vec3f, vec3f2, vec3f3);
        }

(ItemTransform$Deserializer is the original name)

Calling scale/clamp will might modify fallback value if not present

Comments 2

And how does this affect gameplay? Mojang isn't interested in fixing bugs that aren't exposed to players (in other words, bugs in the methods only).

What are the consequences of this?

__xDark

(Unassigned)

Unconfirmed

(Unassigned)

1.17.1

Retrieved