Implement autoplace (#6)

This commit is contained in:
Glease authored and GitHub committed 2022-08-08 17:40:12 +08:00
1 parent e8f5cd6489
commit 609e50428e
60 files changed
+3699 -702

No files matched your search

@@ -1,6 +1,9 @@
package com.gtnewhorizon.structurelib.structure;
import java.util.function.Consumer;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IChatComponent;
import net.minecraft.world.World;
public interface IStructureElementCheckOnly<T> extends IStructureElement<T> {
@@ -13,4 +16,18 @@ public interface IStructureElementCheckOnly<T> extends IStructureElement<T> {
default boolean spawnHint(T t, World world, int x, int y, int z, ItemStack trigger) {
return false;
}
@Override
default PlaceResult survivalPlaceBlock(
T t,
World world,
int x,
int y,
int z,
ItemStack trigger,
IItemSource s,
EntityPlayerMP actor,
Consumer<IChatComponent> chatter) {
return PlaceResult.SKIP;
}
}