diff options
author | Linnea Gräf <nea@nea.moe> | 2024-11-06 16:14:10 +0100 |
---|---|---|
committer | Linnea Gräf <nea@nea.moe> | 2024-11-06 16:14:10 +0100 |
commit | ee21f2da76ea2218ef6a0c6fefa97befa654d115 (patch) | |
tree | aeefb78518a83d37a025673f6cadaa7d89d87449 /src/main/java/moe/nea/firmament/mixins/custommodels/JsonUnbakedModelDataHolder.java | |
parent | ed3e9f0d70a758ac1c23c6c8d67eeb7105d13817 (diff) | |
download | Firmament-ee21f2da76ea2218ef6a0c6fefa97befa654d115.tar.gz Firmament-ee21f2da76ea2218ef6a0c6fefa97befa654d115.tar.bz2 Firmament-ee21f2da76ea2218ef6a0c6fefa97befa654d115.zip |
Fix model unwrapping
Diffstat (limited to 'src/main/java/moe/nea/firmament/mixins/custommodels/JsonUnbakedModelDataHolder.java')
-rw-r--r-- | src/main/java/moe/nea/firmament/mixins/custommodels/JsonUnbakedModelDataHolder.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/moe/nea/firmament/mixins/custommodels/JsonUnbakedModelDataHolder.java b/src/main/java/moe/nea/firmament/mixins/custommodels/JsonUnbakedModelDataHolder.java index 2de2e5e..a5bb34f 100644 --- a/src/main/java/moe/nea/firmament/mixins/custommodels/JsonUnbakedModelDataHolder.java +++ b/src/main/java/moe/nea/firmament/mixins/custommodels/JsonUnbakedModelDataHolder.java @@ -84,7 +84,8 @@ public abstract class JsonUnbakedModelDataHolder implements JsonUnbakedModelFirm if (!this.toString().contains("minecraft") && this.toString().contains("crimson")) { System.out.println("Found non minecraft model " + this); } - if (bakedModel instanceof BakedModelExtra extra) { + var extra = BakedModelExtra.cast(bakedModel); + if (extra != null) { var headModel = getHeadModel_firmament(); if (headModel != null) { extra.setHeadModel_firmament(baker.bake(headModel, ModelRotation.X0_Y0)); |