Rename to Cull Leaves

This commit is contained in:
Motschen
2020-11-28 19:20:04 +01:00
parent 26277f87e5
commit 361a77aa01
7 changed files with 13 additions and 9 deletions

View File

@@ -0,0 +1,24 @@
package eu.midnightdust.cullleaves.mixin;
import net.fabricmc.api.EnvType;
import net.fabricmc.api.Environment;
import net.minecraft.block.Block;
import net.minecraft.block.BlockState;
import net.minecraft.block.LeavesBlock;
import net.minecraft.util.math.Direction;
import org.spongepowered.asm.mixin.Mixin;
@Mixin(LeavesBlock.class)
@Environment(EnvType.CLIENT)
public class MixinLeavesBlock extends Block {
public MixinLeavesBlock(Settings settings) {
super(settings);
}
@Override
@SuppressWarnings("deprecation")
public boolean isSideInvisible(BlockState state, BlockState neighborState, Direction offset) {
return neighborState.getBlock() instanceof LeavesBlock;
}
}