Skip to content

Commit 718a459

Browse files
authored
remove old comments, generalize check (#824)
1 parent a25fa94 commit 718a459

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

src/main/java/com/ldtteam/structurize/placement/StructurePlacer.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
import net.minecraft.world.level.block.*;
2424
import net.minecraft.world.level.block.entity.BlockEntity;
2525
import net.minecraft.world.level.block.state.BlockState;
26+
import net.minecraft.world.level.block.state.properties.BlockStateProperties;
2627
import net.minecraft.world.level.block.state.properties.DoubleBlockHalf;
2728
import net.minecraft.world.level.material.FluidState;
2829
import net.minecraft.world.phys.AABB;
@@ -358,7 +359,7 @@ else if (requiredItems == null)
358359
{
359360
if (!sameBlockInWorld
360361
&& !worldState.isAir()
361-
&& !(worldState.getBlock() instanceof DoublePlantBlock && worldState.getValue(DoublePlantBlock.HALF).equals(DoubleBlockHalf.UPPER)))
362+
&& (!localState.hasProperty(BlockStateProperties.DOUBLE_BLOCK_HALF) || localState.getValue(DoublePlantBlock.HALF).equals(DoubleBlockHalf.LOWER)))
362363
{
363364
removalHandler.handleRemoval(handler, world, worldPos, tileEntityData);
364365
}

src/main/java/com/ldtteam/structurize/placement/handlers/placement/IPlacementHandler.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,10 +48,6 @@ static boolean doesWorldStateMatchBlueprintState(@NotNull BlockInfo blockInfo, @
4848
blockEntityData = new Tuple<>(blockEntity, blockInfo.getTileEntityData());
4949
}
5050

51-
//todo domum blocks on minecol side
52-
//todo minecolonies racks on minecol side
53-
//todo minecolonies allow conversion of dirt like to dirt
54-
5551
return placementHandler.doesWorldStateMatchBlueprintState(structureHandler.getWorld().getBlockState(worldPos), blockInfo.getState(), blockEntityData, structureHandler);
5652
}
5753

0 commit comments

Comments
 (0)