Backport model loading API change to 1.19.4
This commit is contained in:
parent
427a92f0f3
commit
42298947cc
|
|
@ -76,9 +76,13 @@ public abstract class ModelBakeryMixin implements IExtendedModelBakery {
|
|||
|
||||
private boolean ignoreModelLoad;
|
||||
|
||||
// disable fabric recursion
|
||||
@SuppressWarnings("unused")
|
||||
private boolean fabric_enableGetOrLoadModelGuard;
|
||||
|
||||
@Redirect(method = "<init>", at = @At(value = "FIELD", opcode = Opcodes.PUTFIELD, target = "Lnet/minecraft/client/resources/model/ModelBakery;blockColors:Lnet/minecraft/client/color/block/BlockColors;"))
|
||||
private void replaceTopLevelBakedModels(ModelBakery bakery, BlockColors val) {
|
||||
fabric_enableGetOrLoadModelGuard = false;
|
||||
this.blockColors = val;
|
||||
this.ignoreModelLoad = true;
|
||||
this.loadedBakedModels = CacheBuilder.newBuilder()
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user