Skip to content

Commit

Permalink
fix: 🐛 Fixed barrel material recipe deadlock with refined storage 2
Browse files Browse the repository at this point in the history
  • Loading branch information
P3pp3rF1y committed Jan 3, 2025
1 parent 721abb6 commit 03ca751
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ org.gradle.daemon=false

mod_id=sophisticatedstorage
mod_group_id=sophisticatedstorage
mod_version=1.0.6
mod_version=1.0.7
sonar_project_key=sophisticatedstorage:SophisticatedStorage
github_package_url=https://maven.pkg.github.com/P3pp3rF1y/SophisticatedStorage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import net.minecraft.world.item.crafting.CraftingBookCategory;
import net.minecraft.world.item.crafting.CustomRecipe;
import net.minecraft.world.item.crafting.RecipeSerializer;
import net.minecraft.world.level.EmptyBlockGetter;
import net.minecraft.world.level.Level;
import net.minecraft.world.level.block.Block;
import net.minecraftforge.registries.ForgeRegistries;
Expand Down Expand Up @@ -52,7 +53,7 @@ public boolean matches(CraftingContainer container, Level level) {
} else {
return false;
}
} else if (item.getItem() instanceof BlockItem blockItem && Block.isShapeFullBlock(blockItem.getBlock().defaultBlockState().getShape(level, BlockPos.ZERO))) {
} else if (item.getItem() instanceof BlockItem blockItem && Block.isShapeFullBlock(blockItem.getBlock().defaultBlockState().getShape(EmptyBlockGetter.INSTANCE, BlockPos.ZERO))) {
boolean isBottomMiddleAndBottomLeftHasBlock = barrelCol == col && barrelRow < row && rowCounts.getOrDefault(row, 0) > 0;
if (isBottomMiddleAndBottomLeftHasBlock) {
return false;
Expand Down

0 comments on commit 03ca751

Please sign in to comment.