SimpleMultipart/src/main/java/net/shadowfacts/simplemultipart/util/ShapeUtils.java

18 lines
411 B
Java
Raw Normal View History

2018-12-24 22:16:38 +00:00
package net.shadowfacts.simplemultipart.util;
import net.minecraft.util.BooleanBiFunction;
import net.minecraft.util.shape.VoxelShape;
import net.minecraft.util.shape.VoxelShapes;
/**
* @author shadowfacts
*/
public class ShapeUtils {
public static boolean intersect(VoxelShape a, VoxelShape b) {
VoxelShape overlap = VoxelShapes.combine(a, b, BooleanBiFunction.AND);
return !overlap.isEmpty();
}
}