Skip to content

Commit 88b8c7b

Browse files
committed
Fix crash when mining crafting cube
1 parent 1546f3d commit 88b8c7b

3 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/client/java/appeng/client/render/crafting/CraftingCubeModel.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ public Material.Baked particleMaterial() {
259259
return materialFlags;
260260
}
261261

262-
// TODO 26.1: Should implement the location ware materialFlags method to return the flags for the actually used
262+
// TODO 26.1: Should implement the location aware materialFlags method to return the flags for the actually used
263263
// materials
264264

265265
public record Unbaked(CraftingUnitType type) implements CustomUnbakedBlockStateModel {

src/client/java/appeng/client/render/crafting/LightBakedModel.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ protected void addInnerCube(Direction facing, BlockState state, ModelData modelD
4949
builder.setTexture(this.baseTexture);
5050
builder.addCube(x1, y1, z1, x2, y2, z2);
5151

52-
boolean powered = state.getValue(AbstractCraftingUnitBlock.POWERED);
52+
boolean powered = state.getValueOrElse(AbstractCraftingUnitBlock.POWERED, false);
5353
builder.setEmissiveMaterial(powered);
5454
builder.setTexture(this.lightTexture);
5555
builder.addCube(x1, y1, z1, x2, y2, z2);

src/client/java/appeng/client/render/crafting/MonitorBakedModel.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ protected void addInnerCube(Direction side, BlockState state, ModelData modelDat
8282

8383
// Now add the three layered light textures
8484
AEColor color = getColor(modelData);
85-
boolean powered = state.getValue(CraftingMonitorBlock.POWERED);
85+
boolean powered = state.getValueOrElse(CraftingMonitorBlock.POWERED, false);
8686

8787
builder.setEmissiveMaterial(powered);
8888

0 commit comments

Comments
 (0)