Skip to content

Commit

Permalink
Fix critical issues with melting
Browse files Browse the repository at this point in the history
  • Loading branch information
lukebemish committed Dec 26, 2023
1 parent 00e573b commit d421d99
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -570,11 +570,12 @@ private void tryMeltBlock(ServerLevel level, BlockPos toMelt) {
if (levels > 1) {
var newState = stateAbove.setValue(SnowLayerBlock.LAYERS, levels - 1);
level.setBlockAndUpdate(above, newState);
Block.pushEntitiesUp(stateAbove, newState, level, above);
} else {
level.setBlockAndUpdate(above, Blocks.AIR.defaultBlockState());
}
} else if (state.getBlock() == Blocks.SNOW_BLOCK || state.getBlock() == Blocks.POWDER_SNOW) {
level.setBlockAndUpdate(toMelt, Blocks.SNOW.defaultBlockState().setValue(SnowLayerBlock.LAYERS, 7));
} else if (stateAbove.getBlock() == Blocks.POWDER_SNOW) {
level.setBlockAndUpdate(above, Blocks.SNOW.defaultBlockState().setValue(SnowLayerBlock.LAYERS, 7));
}
}
Expand Down

0 comments on commit d421d99

Please sign in to comment.