Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
752 changes: 377 additions & 375 deletions src/generated/resources/.cache/5971ca79ecd127e7d1e65be1cd906ac939e6a245

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"values": [
"#minecraft:portals"
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"values": [
"minecraft:snow"
]
}
2 changes: 2 additions & 0 deletions src/main/java/com/simibubi/create/AllTags.java
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,8 @@ public enum AllBlockTags {
SUGAR_CANE_VARIANTS,
NON_HARVESTABLE,
SINGLE_BLOCK_INVENTORIES,
PLOUGH_WHITELIST,
PLOUGH_BLACKLIST,
CARDBOARD_STORAGE_BLOCKS(FORGE, "storage_blocks/cardboard"),
ANDESITE_ALLOY_STORAGE_BLOCKS(FORGE, "storage_blocks/andesite_alloy"),

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.simibubi.create.content.contraptions.actors.plough;

import com.simibubi.create.AllTags.AllBlockTags;
import com.simibubi.create.content.contraptions.actors.plough.PloughBlock.PloughFakePlayer;
import com.simibubi.create.content.contraptions.behaviour.MovementContext;
import com.simibubi.create.content.kinetics.base.BlockBreakingMovementBehaviour;
Expand All @@ -26,7 +27,6 @@
import net.minecraft.world.level.block.BubbleColumnBlock;
import net.minecraft.world.level.block.FarmBlock;
import net.minecraft.world.level.block.LiquidBlock;
import net.minecraft.world.level.block.NetherPortalBlock;
import net.minecraft.world.level.block.state.BlockState;
import net.minecraft.world.level.storage.loot.LootParams;
import net.minecraft.world.level.storage.loot.parameters.LootContextParams;
Expand Down Expand Up @@ -106,12 +106,14 @@ public boolean canBreak(Level world, BlockPos breakingPos, BlockState state) {
return false;
if (state.getBlock() instanceof BubbleColumnBlock)
return false;
if (state.getBlock() instanceof NetherPortalBlock)
return false;
if (state.getBlock() instanceof ITrackBlock)
return true;
if (state.getBlock() instanceof FakeTrackBlock)
return false;
if (AllBlockTags.PLOUGH_BLACKLIST.matches(state.getBlock()))
return false;
if (AllBlockTags.PLOUGH_WHITELIST.matches(state.getBlock()))
return true;
return state.getCollisionShape(world, breakingPos)
.isEmpty();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,12 @@ private static void genBlockTags(RegistrateTagsProvider<Block> provIn) {
Blocks.BUBBLE_CORAL_WALL_FAN, Blocks.FIRE_CORAL_WALL_FAN, Blocks.HORN_CORAL_WALL_FAN
);

prov.tag(AllBlockTags.PLOUGH_WHITELIST.tag)
.add(Blocks.SNOW);

prov.tag(AllBlockTags.PLOUGH_BLACKLIST.tag)
.addTag(BlockTags.PORTALS);

// COMPAT

TagGen.addOptional(prov.tag(AllBlockTags.NON_MOVABLE.tag), Mods.IE, List.of(
Expand Down