mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-27 15:23:16 +00:00
* Return block face shape data for various blocks. Fixes #5530 * Allow for bounding block tile owners to control the face shape
37 lines
1.0 KiB
Java
37 lines
1.0 KiB
Java
package mekanism.common.base;
|
|
|
|
import javax.annotation.Nonnull;
|
|
import net.minecraft.block.state.BlockFaceShape;
|
|
import net.minecraft.util.EnumFacing;
|
|
import net.minecraft.util.math.Vec3i;
|
|
|
|
/**
|
|
* Internal interface. A bounding block is not actually a 'bounding' block, it is really just a fake block that is used to mimic actual block bounds.
|
|
*
|
|
* @author AidanBrady
|
|
*/
|
|
public interface IBoundingBlock {
|
|
|
|
/**
|
|
* Called when the main block is placed.
|
|
*/
|
|
void onPlace();
|
|
|
|
/**
|
|
* Called when any part of the structure is broken.
|
|
*/
|
|
void onBreak();
|
|
|
|
/**
|
|
* Used for getting the proper BlockFaceShape for the bounding block.
|
|
*
|
|
* @param face The face of the block at the offset that the shape is needed for.
|
|
* @param offset Offset from the implementation of IBoundingBlock
|
|
*
|
|
* @return A BlockFaceShape
|
|
*/
|
|
@Nonnull
|
|
default BlockFaceShape getOffsetBlockFaceShape(@Nonnull EnumFacing face, @Nonnull Vec3i offset) {
|
|
return BlockFaceShape.UNDEFINED;
|
|
}
|
|
} |