mirror of
https://github.com/Ellpeck/PrettyPipes.git
synced 2024-11-22 03:43:30 +01:00
resolved some TODOs
This commit is contained in:
parent
c8c0db6aa9
commit
6cb3e6e57e
3 changed files with 4 additions and 6 deletions
|
@ -10,7 +10,6 @@ import java.util.function.Supplier;
|
|||
public class ItemEquality {
|
||||
|
||||
public static final ItemEquality DAMAGE = new ItemEquality((stack, filter) -> stack.getDamageValue() == filter.getDamageValue(), false, Type.DAMAGE);
|
||||
// TODO see if this tagMatches replacement is good enough?
|
||||
public static final ItemEquality NBT = new ItemEquality(ItemStack::areShareTagsEqual, false, Type.NBT);
|
||||
public static final ItemEquality MOD = new ItemEquality((stack, filter) -> stack.getItem().getCreatorModId(stack).equals(filter.getItem().getCreatorModId(filter)), true, Type.MOD);
|
||||
|
||||
|
|
|
@ -39,8 +39,6 @@ public class ItemTerminalWidget extends AbstractWidget {
|
|||
@Override
|
||||
protected void renderWidget(GuiGraphics graphics, int p_268034_, int p_268009_, float p_268085_) {
|
||||
var mc = this.screen.getMinecraft();
|
||||
var renderer = mc.getItemRenderer();
|
||||
// TODO test this new blit offset replacement?
|
||||
graphics.pose().translate(0, 0, 100);
|
||||
if (this.selected)
|
||||
graphics.fill(this.getX(), this.getY(), this.getX() + 16, this.getY() + 16, -2130706433);
|
||||
|
|
|
@ -28,6 +28,7 @@ import net.minecraft.world.level.block.state.properties.BlockStateProperties;
|
|||
import net.minecraft.world.level.block.state.properties.EnumProperty;
|
||||
import net.minecraft.world.level.material.FluidState;
|
||||
import net.minecraft.world.level.material.Fluids;
|
||||
import net.minecraft.world.level.material.MapColor;
|
||||
import net.minecraft.world.phys.BlockHitResult;
|
||||
import net.minecraft.world.phys.shapes.BooleanOp;
|
||||
import net.minecraft.world.phys.shapes.CollisionContext;
|
||||
|
@ -224,9 +225,9 @@ public class PipeBlock extends BaseEntityBlock {
|
|||
protected static boolean hasLegsTo(Level world, BlockState state, BlockPos pos, Direction direction) {
|
||||
if (state.getBlock() instanceof WallBlock || state.getBlock() instanceof FenceBlock)
|
||||
return direction == Direction.DOWN;
|
||||
// TODO figure out new condition for legs now that materials are gone
|
||||
/* if (state.getMaterial() == Material.STONE || state.getMaterial() == Material.METAL)
|
||||
return Block.canSupportCenter(world, pos, direction.getOpposite());*/
|
||||
var mapColor = state.getMapColor(world,pos);
|
||||
if (mapColor == MapColor.STONE || mapColor == MapColor.METAL)
|
||||
return Block.canSupportCenter(world, pos, direction.getOpposite());
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue