mojira.dev
MC-262472

Avoidable redundancy in cauldron model definitions

The bug

The models for cauldrons containing something point to one of three template models. These template models entirely duplicate the cauldron model, with the only difference being a single texture plane on the inside.

As the cauldron is one of the most complex models in the game (58 planes), to then duplicate that model three times is wasteful. It is also rather confusing, as any changes made to the model of the normal cauldron will not apply when the cauldron gains contents, forcing resource pack creators to then duplicate their custom cauldron model to avert this.

How to fix

This problem can be resolved via a multipart approach. We keep the normal cauldron model, and discard everything about the three template models except for the fluid plane (in the attached resource pack, I've renamed the template models, as well as the models that reference them, to make their purposes clearer). This means that there only exists a single cauldron model in the game - the three templates only represent the fluid level.

In the blockstates directory, it's fairly simple to define the necessary data for the three cauldron types. We apply the cauldron model, and then apply one of the fluid level models depending on how high the fluid is.

If we add up the size of each individual json file, this new approach only requires 1.98 KB, which is almost a third of the size of one of the current vanilla template models. Doing the same for vanilla's current approach brings us to a total of 19.73 KB.

Related issues

Attachments

Comments

migrated
[media]
Moesh

Please send feedback to feedback.minecraft.net.

migrated

Shouldn't this be considered in the same way as lag reports or unused assets? It falls in a similar category as fixing this would reduce game file size and possibly reduce memory used.

muzikbike

(Unassigned)

Plausible

(Unassigned)

1.19.4, 23w18a

Retrieved