From 65372144035dda2de6d0cddd4486f0a5efd94226 Mon Sep 17 00:00:00 2001 From: simibubi <31564874+simibubi@users.noreply.github.com> Date: Thu, 13 Feb 2020 18:35:14 +0100 Subject: [PATCH] Reworked the Belt Observer - Belt observers now have four modes with different useful behaviours #83 - Fixed belt actors not syncing when items are not held in place but replaced - Upward facing deployers can now act as item displays - Fixed deployer fake players persisting after disassembling a portable contraption - Creepers no longer take revenge on Deployers by default --- .../com/simibubi/create/config/CKinetics.java | 10 +- .../simibubi/create/config/ConfigBase.java | 13 ++ .../deployer/DeployerFakePlayer.java | 30 +++++ .../deployer/DeployerMovementBehaviour.java | 6 +- .../deployer/DeployerTileEntityRenderer.java | 32 +++-- .../relays/belt/BeltInventory.java | 3 + .../relays/belt/BeltTileEntity.java | 6 + .../block/belts/BeltObserverBlock.java | 127 ++++++++++++++---- .../block/belts/BeltObserverTileEntity.java | 60 +++++++++ .../create/blockstates/entity_detector.json | 95 ++++++++++--- .../resources/assets/create/lang/en_us.json | 14 +- .../base.json} | 6 +- .../base_belt.json} | 6 +- .../belt_observer/base_belt_powered.json | 6 + .../block/belt_observer/base_powered.json | 6 + .../models/block/belt_observer/detect.json | 6 + .../block/belt_observer/detect_belt.json | 6 + .../belt_observer/detect_belt_powered.json | 6 + .../block/belt_observer/detect_powered.json | 6 + .../models/block/belt_observer/eject.json | 6 + .../block/belt_observer/eject_belt.json | 6 + .../belt_observer/eject_belt_powered.json | 6 + .../block/belt_observer/eject_powered.json | 6 + .../models/block/belt_observer/pulse.json | 6 + .../block/belt_observer/pulse_belt.json | 6 + .../belt_observer/pulse_belt_powered.json | 6 + .../block/belt_observer/pulse_powered.json | 6 + .../models/block/belt_observer/split.json | 6 + .../block/belt_observer/split_belt.json | 6 + .../belt_observer/split_belt_powered.json | 6 + .../block/belt_observer/split_powered.json | 6 + .../models/block/entity_detector_powered.json | 8 -- .../entity_detector_with_belt_powered.json | 8 -- .../create/models/item/entity_detector.json | 4 +- .../textures/block/belt_observer_detect.png | Bin 0 -> 518 bytes .../block/belt_observer_detect_powered.png | Bin 0 -> 507 bytes .../textures/block/belt_observer_eject.png | Bin 0 -> 532 bytes .../block/belt_observer_eject_powered.png | Bin 0 -> 564 bytes ...ctor_front.png => belt_observer_front.png} | Bin .../textures/block/belt_observer_pulse.png | Bin 0 -> 541 bytes .../block/belt_observer_pulse_powered.png | Bin 0 -> 560 bytes .../textures/block/belt_observer_split.png | Bin 0 -> 557 bytes .../block/belt_observer_split_powered.png | Bin 0 -> 557 bytes .../create/textures/block/clutch_off.png | Bin 426 -> 547 bytes .../textures/block/entity_detector_off.png | Bin 529 -> 0 bytes .../textures/block/entity_detector_on.png | Bin 544 -> 0 bytes 46 files changed, 454 insertions(+), 82 deletions(-) rename src/main/resources/assets/create/models/block/{entity_detector.json => belt_observer/base.json} (96%) rename src/main/resources/assets/create/models/block/{entity_detector_with_belt.json => belt_observer/base_belt.json} (96%) create mode 100644 src/main/resources/assets/create/models/block/belt_observer/base_belt_powered.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/base_powered.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/detect.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/detect_belt.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/detect_belt_powered.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/detect_powered.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/eject.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/eject_belt.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/eject_belt_powered.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/eject_powered.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/pulse.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/pulse_belt.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/pulse_belt_powered.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/pulse_powered.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/split.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/split_belt.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/split_belt_powered.json create mode 100644 src/main/resources/assets/create/models/block/belt_observer/split_powered.json delete mode 100644 src/main/resources/assets/create/models/block/entity_detector_powered.json delete mode 100644 src/main/resources/assets/create/models/block/entity_detector_with_belt_powered.json create mode 100644 src/main/resources/assets/create/textures/block/belt_observer_detect.png create mode 100644 src/main/resources/assets/create/textures/block/belt_observer_detect_powered.png create mode 100644 src/main/resources/assets/create/textures/block/belt_observer_eject.png create mode 100644 src/main/resources/assets/create/textures/block/belt_observer_eject_powered.png rename src/main/resources/assets/create/textures/block/{entity_detector_front.png => belt_observer_front.png} (100%) create mode 100644 src/main/resources/assets/create/textures/block/belt_observer_pulse.png create mode 100644 src/main/resources/assets/create/textures/block/belt_observer_pulse_powered.png create mode 100644 src/main/resources/assets/create/textures/block/belt_observer_split.png create mode 100644 src/main/resources/assets/create/textures/block/belt_observer_split_powered.png delete mode 100644 src/main/resources/assets/create/textures/block/entity_detector_off.png delete mode 100644 src/main/resources/assets/create/textures/block/entity_detector_on.png diff --git a/src/main/java/com/simibubi/create/config/CKinetics.java b/src/main/java/com/simibubi/create/config/CKinetics.java index bdb8c6e1e..47383e45b 100644 --- a/src/main/java/com/simibubi/create/config/CKinetics.java +++ b/src/main/java/com/simibubi/create/config/CKinetics.java @@ -6,6 +6,8 @@ public class CKinetics extends ConfigBase { public ConfigInt crushingDamage = i(4, 0, "crushingDamage", Comments.crushingDamage); public ConfigInt maxMotorSpeed = i(256, 64, "maxMotorSpeed", Comments.rpm, Comments.maxMotorSpeed); public ConfigInt maxRotationSpeed = i(256, 64, "maxRotationSpeed", Comments.rpm, Comments.maxRotationSpeed); + public ConfigEnum ignoreDeployerAttacks = + e(DeployerAggroSetting.CREEPERS, "ignoreDeployerAttacks", Comments.ignoreDeployerAttacks); public ConfigGroup fan = group(0, "encasedFan", "Encased Fan"); public ConfigInt fanPushDistance = i(20, 5, "fanPushDistance", Comments.fanPushDistance); @@ -24,7 +26,8 @@ public class CKinetics extends ConfigBase { public ConfigGroup state = group(0, "stats", Comments.stats); public ConfigFloat mediumSpeed = f(30, 0, 4096, "mediumSpeed", Comments.rpm, Comments.mediumSpeed); public ConfigFloat fastSpeed = f(100, 0, 65535, "fastSpeed", Comments.rpm, Comments.fastSpeed); - public ConfigFloat mediumStressImpact = f(8, 0, 4096, "mediumStressImpact", Comments.su, Comments.mediumStressImpact); + public ConfigFloat mediumStressImpact = + f(8, 0, 4096, "mediumStressImpact", Comments.su, Comments.mediumStressImpact); public ConfigFloat highStressImpact = f(32, 0, 65535, "highStressImpact", Comments.su, Comments.highStressImpact); public ConfigFloat mediumCapacity = f(128, 0, 4096, "mediumCapacity", Comments.su, Comments.mediumCapacity); public ConfigFloat highCapacity = f(512, 0, 65535, "highCapacity", Comments.su, Comments.highCapacity); @@ -61,6 +64,11 @@ public class CKinetics extends ConfigBase { static String mediumCapacity = "Minimum added Capacity by sources to be considered 'medium'"; static String highCapacity = "Minimum added Capacity by sources to be considered 'high'"; static String stress = "Fine tune the kinetic stats of individual components"; + static String ignoreDeployerAttacks = "Select what mobs should ignore Deployers when attacked by them."; + } + + public static enum DeployerAggroSetting { + ALL, CREEPERS, NONE } } diff --git a/src/main/java/com/simibubi/create/config/ConfigBase.java b/src/main/java/com/simibubi/create/config/ConfigBase.java index 8af7f4ac6..98fe50800 100644 --- a/src/main/java/com/simibubi/create/config/ConfigBase.java +++ b/src/main/java/com/simibubi/create/config/ConfigBase.java @@ -10,6 +10,7 @@ import net.minecraftforge.common.ForgeConfigSpec.BooleanValue; import net.minecraftforge.common.ForgeConfigSpec.Builder; import net.minecraftforge.common.ForgeConfigSpec.ConfigValue; import net.minecraftforge.common.ForgeConfigSpec.DoubleValue; +import net.minecraftforge.common.ForgeConfigSpec.EnumValue; import net.minecraftforge.common.ForgeConfigSpec.IntValue; public abstract class ConfigBase { @@ -61,6 +62,10 @@ public abstract class ConfigBase { protected ConfigInt i(int current, int min, String name, String... comment) { return i(current, min, Integer.MAX_VALUE, name, comment); } + + protected > ConfigEnum e(T defaultValue, String name, String... comment) { + return new ConfigEnum<>(name, defaultValue, comment); + } protected ConfigGroup group(int depth, String name, String... comment) { return new ConfigGroup(name, depth, comment); @@ -153,6 +158,14 @@ public abstract class ConfigBase { super(name, builder -> builder.define(name, def), comment); } } + + public class ConfigEnum> extends CValue> { + + public ConfigEnum(String name, T defaultValue, String[] comment) { + super(name, builder -> builder.defineEnum(name, defaultValue), comment); + } + + } public class ConfigFloat extends CValue { diff --git a/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerFakePlayer.java b/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerFakePlayer.java index cefd52f8d..545687ac6 100644 --- a/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerFakePlayer.java +++ b/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerFakePlayer.java @@ -6,12 +6,17 @@ import java.util.UUID; import org.apache.commons.lang3.tuple.Pair; import com.mojang.authlib.GameProfile; +import com.simibubi.create.config.AllConfigs; +import com.simibubi.create.config.CKinetics; import com.simibubi.create.foundation.utility.Lang; import io.netty.util.concurrent.Future; import io.netty.util.concurrent.GenericFutureListener; import net.minecraft.entity.Entity; +import net.minecraft.entity.LivingEntity; +import net.minecraft.entity.MobEntity; import net.minecraft.entity.Pose; +import net.minecraft.entity.monster.CreeperEntity; import net.minecraft.entity.player.ServerPlayerEntity; import net.minecraft.inventory.container.INamedContainerProvider; import net.minecraft.item.ItemStack; @@ -32,6 +37,7 @@ import net.minecraftforge.common.util.FakePlayer; import net.minecraftforge.event.entity.EntityEvent; import net.minecraftforge.event.entity.living.LivingDropsEvent; import net.minecraftforge.event.entity.living.LivingExperienceDropEvent; +import net.minecraftforge.event.entity.living.LivingSetAttackTargetEvent; import net.minecraftforge.eventbus.api.SubscribeEvent; import net.minecraftforge.fml.common.Mod.EventBusSubscriber; @@ -107,6 +113,30 @@ public class DeployerFakePlayer extends FakePlayer { event.setCanceled(true); } + @SubscribeEvent + public static void entitiesDontRetaliate(LivingSetAttackTargetEvent event) { + if (!(event.getTarget() instanceof DeployerFakePlayer)) + return; + LivingEntity entityLiving = event.getEntityLiving(); + if (!(entityLiving instanceof MobEntity)) + return; + MobEntity mob = (MobEntity) entityLiving; + + CKinetics.DeployerAggroSetting setting = AllConfigs.SERVER.kinetics.ignoreDeployerAttacks.get(); + + switch (setting) { + case ALL: + mob.setAttackTarget(null); + break; + case CREEPERS: + if (mob instanceof CreeperEntity) + mob.setAttackTarget(null); + break; + case NONE: + default: + } + } + private static class FakePlayNetHandler extends ServerPlayNetHandler { public FakePlayNetHandler(MinecraftServer server, ServerPlayerEntity playerIn) { super(server, NETWORK_MANAGER, playerIn); diff --git a/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerMovementBehaviour.java b/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerMovementBehaviour.java index f46165b24..67ca519b1 100644 --- a/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerMovementBehaviour.java +++ b/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerMovementBehaviour.java @@ -91,8 +91,12 @@ public class DeployerMovementBehaviour extends MovementBehaviour { if (context.world.isRemote) return; tryDisposeOfEverything(context); + DeployerFakePlayer player = getPlayer(context); + if (player == null) + return; + player.remove(); } - + private void tryGrabbingItem(MovementContext context) { DeployerFakePlayer player = getPlayer(context); if (player == null) diff --git a/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerTileEntityRenderer.java b/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerTileEntityRenderer.java index 63f200861..bc397d1df 100644 --- a/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerTileEntityRenderer.java +++ b/src/main/java/com/simibubi/create/modules/contraptions/components/deployer/DeployerTileEntityRenderer.java @@ -13,6 +13,7 @@ import com.simibubi.create.AllBlocks; import com.simibubi.create.foundation.behaviour.filtering.FilteringRenderer; import com.simibubi.create.foundation.block.SafeTileEntityRenderer; import com.simibubi.create.foundation.utility.AngleHelper; +import com.simibubi.create.foundation.utility.AnimationTickHolder; import com.simibubi.create.foundation.utility.NBTHelper; import com.simibubi.create.foundation.utility.SuperByteBuffer; import com.simibubi.create.foundation.utility.TessellatorHelper; @@ -62,22 +63,37 @@ public class DeployerTileEntityRenderer extends SafeTileEntityRenderer, IBeltAttachment { + implements IWithTileEntity, IBeltAttachment, IWrenchable { - public static BooleanProperty POWERED = BlockStateProperties.POWERED; - public static BooleanProperty BELT = BooleanProperty.create("belt"); + public static final BooleanProperty POWERED = BlockStateProperties.POWERED; + public static final BooleanProperty BELT = BooleanProperty.create("belt"); + public static final EnumProperty MODE = EnumProperty.create("mode", Mode.class); public BeltObserverBlock() { super(Properties.from(Blocks.ANDESITE)); @@ -64,7 +77,7 @@ public class BeltObserverBlock extends HorizontalBlock @Override protected void fillStateContainer(Builder builder) { - builder.add(POWERED, HORIZONTAL_FACING, BELT); + builder.add(POWERED, HORIZONTAL_FACING, BELT, MODE); super.fillStateContainer(builder); } @@ -167,52 +180,93 @@ public class BeltObserverBlock extends HorizontalBlock @Override public boolean startProcessingItem(BeltTileEntity te, TransportedItemStack transported, BeltAttachmentState state) { - state.processingDuration = 0; - FilteringBehaviour behaviour = TileEntityBehaviour.get(te.getWorld(), state.attachmentPos, - FilteringBehaviour.TYPE); - if (behaviour != null) { - if (!behaviour.test(transported.stack)) { - state.processingDuration = -1; - return false; + World world = te.getWorld(); + BlockState blockState = world.getBlockState(state.attachmentPos); + if (blockState.get(MODE) == Mode.DETECT) + return false; + + FilteringBehaviour behaviour = + TileEntityBehaviour.get(te.getWorld(), state.attachmentPos, FilteringBehaviour.TYPE); + if (behaviour != null && !behaviour.test(transported.stack)) + return false; + + world.setBlockState(state.attachmentPos, blockState.with(POWERED, true)); + world.notifyNeighborsOfStateChange(state.attachmentPos, this); + withTileEntityDo(world, state.attachmentPos, BeltObserverTileEntity::resetTurnOffCooldown); + + Mode mode = blockState.get(MODE); + if (mode == Mode.EJECT || mode == Mode.SPLIT) { + ItemStack copy = transported.stack.copy(); + ItemStack toEject = mode == Mode.EJECT ? transported.stack : copy.split(transported.stack.getCount() / 2); + + if (!toEject.isEmpty()) { + if (!eject(world, toEject, state.attachmentPos, blockState.get(HORIZONTAL_FACING))) + return true; + transported.stack = mode == Mode.EJECT ? ItemStack.EMPTY : copy; } } + return false; + } + + @Override + public boolean processItem(BeltTileEntity te, TransportedItemStack transported, BeltAttachmentState state) { World world = te.getWorld(); BlockState blockState = world.getBlockState(state.attachmentPos); - if (state.processingDuration == 0) { - world.setBlockState(state.attachmentPos, blockState.with(POWERED, true)); - world.getPendingBlockTicks().scheduleTick(state.attachmentPos, this, 6); - world.notifyNeighborsOfStateChange(state.attachmentPos, this); - return true; + withTileEntityDo(world, state.attachmentPos, BeltObserverTileEntity::resetTurnOffCooldown); + + Mode mode = blockState.get(MODE); + if (mode == Mode.EJECT || mode == Mode.SPLIT) { + ItemStack copy = transported.stack.copy(); + ItemStack toEject = mode == Mode.EJECT ? transported.stack : copy.split(transported.stack.getCount() / 2); + + if (!eject(world, toEject, state.attachmentPos, blockState.get(HORIZONTAL_FACING))) + return true; + transported.stack = mode == Mode.EJECT ? ItemStack.EMPTY : copy; } + return false; } + private boolean eject(World world, ItemStack stack, BlockPos observerPos, Direction facing) { + BlockPos potentialBeltPos = observerPos.offset(facing, 2); + TileEntity tileEntity = world.getTileEntity(potentialBeltPos); + if (tileEntity instanceof BeltTileEntity) { + BeltTileEntity belt = (BeltTileEntity) tileEntity; + return belt.tryInsertingFromSide(facing, stack, false); + } + + boolean empty = world.getBlockState(potentialBeltPos).getCollisionShape(world, potentialBeltPos).isEmpty(); + float yOffset = empty ? 0 : .5f; + AxisAlignedBB bb = new AxisAlignedBB(empty ? potentialBeltPos : potentialBeltPos.up()); + if (!world.getEntitiesWithinAABBExcludingEntity(null, bb).isEmpty()) + return false; + + Vec3d motion = new Vec3d(facing.getDirectionVec()).scale(1 / 16f); + Vec3d entityPos = VecHelper.getCenterOf(potentialBeltPos).add(0, yOffset + .25f, 0).subtract(motion); + ItemEntity entity = new ItemEntity(world, entityPos.x, entityPos.y, entityPos.z, stack); + entity.setMotion(motion); + entity.setPickupDelay(5); + world.playSound(null, observerPos, SoundEvents.ENTITY_ITEM_PICKUP, SoundCategory.BLOCKS, .125f, .1f); + world.addEntity(entity); + return true; + } + @Override public boolean processEntity(BeltTileEntity te, Entity entity, BeltAttachmentState state) { if (te.getWorld().isRemote) return false; - - if (state.processingEntity != entity) { - state.processingEntity = entity; - state.processingDuration = 0; - } - if (entity.getPositionVec().distanceTo(VecHelper.getCenterOf(te.getPos())) > .5f) return false; - if (state.processingDuration == -1) { - return false; - } World world = te.getWorld(); BlockState blockState = world.getBlockState(state.attachmentPos); if (blockState.get(POWERED)) return false; - state.processingDuration = -1; world.setBlockState(state.attachmentPos, blockState.with(POWERED, true)); - world.getPendingBlockTicks().scheduleTick(state.attachmentPos, this, 6); world.notifyNeighborsOfStateChange(state.attachmentPos, this); + withTileEntityDo(te.getWorld(), state.attachmentPos, BeltObserverTileEntity::resetTurnOffCooldown); return false; } @@ -222,4 +276,23 @@ public class BeltObserverBlock extends HorizontalBlock worldIn.notifyNeighborsOfStateChange(pos, this); } + @Override + public ActionResultType onWrenched(BlockState state, ItemUseContext context) { + World world = context.getWorld(); + if (!world.isRemote) { + world.setBlockState(context.getPos(), state.with(POWERED, false).cycle(MODE), 3); + world.notifyNeighborsOfStateChange(context.getPos(), this); + } + return ActionResultType.SUCCESS; + } + + public enum Mode implements IStringSerializable { + DETECT, PULSE, EJECT, SPLIT; + + @Override + public String getName() { + return Lang.asId(name()); + } + } + } diff --git a/src/main/java/com/simibubi/create/modules/logistics/block/belts/BeltObserverTileEntity.java b/src/main/java/com/simibubi/create/modules/logistics/block/belts/BeltObserverTileEntity.java index fcff01bc4..7aa8351f0 100644 --- a/src/main/java/com/simibubi/create/modules/logistics/block/belts/BeltObserverTileEntity.java +++ b/src/main/java/com/simibubi/create/modules/logistics/block/belts/BeltObserverTileEntity.java @@ -9,8 +9,12 @@ import com.simibubi.create.foundation.behaviour.filtering.FilteringBehaviour; import com.simibubi.create.foundation.behaviour.filtering.FilteringBehaviour.SlotPositioning; import com.simibubi.create.foundation.utility.AngleHelper; import com.simibubi.create.foundation.utility.VecHelper; +import com.simibubi.create.modules.contraptions.relays.belt.BeltTileEntity; +import com.simibubi.create.modules.logistics.block.belts.BeltObserverBlock.Mode; import net.minecraft.block.HorizontalBlock; +import net.minecraft.nbt.CompoundNBT; +import net.minecraft.tileentity.TileEntity; import net.minecraft.util.Direction.Axis; import net.minecraft.util.math.Vec3d; @@ -18,9 +22,65 @@ public class BeltObserverTileEntity extends SmartTileEntity { private static FilteringBehaviour.SlotPositioning slots; private FilteringBehaviour filtering; + public int turnOffTicks = 0; public BeltObserverTileEntity() { super(AllTileEntities.ENTITY_DETECTOR.type); + setLazyTickRate(20); + } + + @Override + public void tick() { + super.tick(); + if (turnOffTicks > 0) { + turnOffTicks--; + if (turnOffTicks == 0) + world.getPendingBlockTicks().scheduleTick(pos, getBlockState().getBlock(), 1); + } + + if (!isActive()) + return; + if (getBlockState().get(BeltObserverBlock.MODE) != Mode.DETECT) + return; + + TileEntity tileEntity = + world.getTileEntity(pos.offset(getBlockState().get(BeltObserverBlock.HORIZONTAL_FACING))); + if (!(tileEntity instanceof BeltTileEntity)) + return; + BeltTileEntity belt = (BeltTileEntity) tileEntity; + BeltTileEntity controllerTE = belt.getControllerTE(); + if (controllerTE == null) + return; + + controllerTE.getInventory().forEachWithin(belt.index + .5f, .45f, stack -> { + if (filtering.test(stack.stack) && turnOffTicks != 6) { + world.setBlockState(pos, getBlockState().with(BeltObserverBlock.POWERED, true)); + world.notifyNeighborsOfStateChange(pos, getBlockState().getBlock()); + resetTurnOffCooldown(); + } + return null; + }); + + } + + private boolean isActive() { + return getBlockState().get(BeltObserverBlock.BELT); + } + + public void resetTurnOffCooldown() { + turnOffTicks = 6; + } + + @Override + public CompoundNBT write(CompoundNBT compound) { + compound.putInt("TurnOff", turnOffTicks); + return super.write(compound); + } + + @Override + public void read(CompoundNBT compound) { + turnOffTicks = compound.getInt("TurnOff"); + super.read(compound); } @Override diff --git a/src/main/resources/assets/create/blockstates/entity_detector.json b/src/main/resources/assets/create/blockstates/entity_detector.json index f6a252d3b..50543c629 100644 --- a/src/main/resources/assets/create/blockstates/entity_detector.json +++ b/src/main/resources/assets/create/blockstates/entity_detector.json @@ -1,23 +1,86 @@ { "variants": { - "powered=false,belt=false,facing=south": { "model": "create:block/entity_detector", "y": 0 }, - "powered=false,belt=false,facing=east": { "model": "create:block/entity_detector", "y": 270 }, - "powered=false,belt=false,facing=north": { "model": "create:block/entity_detector", "y": 180 }, - "powered=false,belt=false,facing=west": { "model": "create:block/entity_detector", "y": 90 }, + "mode=detect,powered=false,belt=false,facing=south": { "model": "create:block/belt_observer/detect", "y": 0 }, + "mode=detect,powered=false,belt=false,facing=east": { "model": "create:block/belt_observer/detect", "y": 270 }, + "mode=detect,powered=false,belt=false,facing=north": { "model": "create:block/belt_observer/detect", "y": 180 }, + "mode=detect,powered=false,belt=false,facing=west": { "model": "create:block/belt_observer/detect", "y": 90 }, - "powered=true,belt=false,facing=south": { "model": "create:block/entity_detector_powered", "y": 0 }, - "powered=true,belt=false,facing=east": { "model": "create:block/entity_detector_powered", "y": 270 }, - "powered=true,belt=false,facing=north": { "model": "create:block/entity_detector_powered", "y": 180 }, - "powered=true,belt=false,facing=west": { "model": "create:block/entity_detector_powered", "y": 90 }, + "mode=detect,powered=true,belt=false,facing=south": { "model": "create:block/belt_observer/detect_powered", "y": 0 }, + "mode=detect,powered=true,belt=false,facing=east": { "model": "create:block/belt_observer/detect_powered", "y": 270 }, + "mode=detect,powered=true,belt=false,facing=north": { "model": "create:block/belt_observer/detect_powered", "y": 180 }, + "mode=detect,powered=true,belt=false,facing=west": { "model": "create:block/belt_observer/detect_powered", "y": 90 }, - "powered=false,belt=true,facing=south": { "model": "create:block/entity_detector_with_belt", "y": 0 }, - "powered=false,belt=true,facing=east": { "model": "create:block/entity_detector_with_belt", "y": 270 }, - "powered=false,belt=true,facing=north": { "model": "create:block/entity_detector_with_belt", "y": 180 }, - "powered=false,belt=true,facing=west": { "model": "create:block/entity_detector_with_belt", "y": 90 }, + "mode=detect,powered=false,belt=true,facing=south": { "model": "create:block/belt_observer/detect_belt", "y": 0 }, + "mode=detect,powered=false,belt=true,facing=east": { "model": "create:block/belt_observer/detect_belt", "y": 270 }, + "mode=detect,powered=false,belt=true,facing=north": { "model": "create:block/belt_observer/detect_belt", "y": 180 }, + "mode=detect,powered=false,belt=true,facing=west": { "model": "create:block/belt_observer/detect_belt", "y": 90 }, - "powered=true,belt=true,facing=south": { "model": "create:block/entity_detector_with_belt_powered", "y": 0 }, - "powered=true,belt=true,facing=east": { "model": "create:block/entity_detector_with_belt_powered", "y": 270 }, - "powered=true,belt=true,facing=north": { "model": "create:block/entity_detector_with_belt_powered", "y": 180 }, - "powered=true,belt=true,facing=west": { "model": "create:block/entity_detector_with_belt_powered", "y": 90 } + "mode=detect,powered=true,belt=true,facing=south": { "model": "create:block/belt_observer/detect_belt_powered", "y": 0 }, + "mode=detect,powered=true,belt=true,facing=east": { "model": "create:block/belt_observer/detect_belt_powered", "y": 270 }, + "mode=detect,powered=true,belt=true,facing=north": { "model": "create:block/belt_observer/detect_belt_powered", "y": 180 }, + "mode=detect,powered=true,belt=true,facing=west": { "model": "create:block/belt_observer/detect_belt_powered", "y": 90 }, + + + "mode=pulse,powered=false,belt=false,facing=south": { "model": "create:block/belt_observer/pulse", "y": 0 }, + "mode=pulse,powered=false,belt=false,facing=east": { "model": "create:block/belt_observer/pulse", "y": 270 }, + "mode=pulse,powered=false,belt=false,facing=north": { "model": "create:block/belt_observer/pulse", "y": 180 }, + "mode=pulse,powered=false,belt=false,facing=west": { "model": "create:block/belt_observer/pulse", "y": 90 }, + + "mode=pulse,powered=true,belt=false,facing=south": { "model": "create:block/belt_observer/pulse_powered", "y": 0 }, + "mode=pulse,powered=true,belt=false,facing=east": { "model": "create:block/belt_observer/pulse_powered", "y": 270 }, + "mode=pulse,powered=true,belt=false,facing=north": { "model": "create:block/belt_observer/pulse_powered", "y": 180 }, + "mode=pulse,powered=true,belt=false,facing=west": { "model": "create:block/belt_observer/pulse_powered", "y": 90 }, + + "mode=pulse,powered=false,belt=true,facing=south": { "model": "create:block/belt_observer/pulse_belt", "y": 0 }, + "mode=pulse,powered=false,belt=true,facing=east": { "model": "create:block/belt_observer/pulse_belt", "y": 270 }, + "mode=pulse,powered=false,belt=true,facing=north": { "model": "create:block/belt_observer/pulse_belt", "y": 180 }, + "mode=pulse,powered=false,belt=true,facing=west": { "model": "create:block/belt_observer/pulse_belt", "y": 90 }, + + "mode=pulse,powered=true,belt=true,facing=south": { "model": "create:block/belt_observer/pulse_belt_powered", "y": 0 }, + "mode=pulse,powered=true,belt=true,facing=east": { "model": "create:block/belt_observer/pulse_belt_powered", "y": 270 }, + "mode=pulse,powered=true,belt=true,facing=north": { "model": "create:block/belt_observer/pulse_belt_powered", "y": 180 }, + "mode=pulse,powered=true,belt=true,facing=west": { "model": "create:block/belt_observer/pulse_belt_powered", "y": 90 }, + + + "mode=eject,powered=false,belt=false,facing=south": { "model": "create:block/belt_observer/eject", "y": 0 }, + "mode=eject,powered=false,belt=false,facing=east": { "model": "create:block/belt_observer/eject", "y": 270 }, + "mode=eject,powered=false,belt=false,facing=north": { "model": "create:block/belt_observer/eject", "y": 180 }, + "mode=eject,powered=false,belt=false,facing=west": { "model": "create:block/belt_observer/eject", "y": 90 }, + + "mode=eject,powered=true,belt=false,facing=south": { "model": "create:block/belt_observer/eject_powered", "y": 0 }, + "mode=eject,powered=true,belt=false,facing=east": { "model": "create:block/belt_observer/eject_powered", "y": 270 }, + "mode=eject,powered=true,belt=false,facing=north": { "model": "create:block/belt_observer/eject_powered", "y": 180 }, + "mode=eject,powered=true,belt=false,facing=west": { "model": "create:block/belt_observer/eject_powered", "y": 90 }, + + "mode=eject,powered=false,belt=true,facing=south": { "model": "create:block/belt_observer/eject_belt", "y": 0 }, + "mode=eject,powered=false,belt=true,facing=east": { "model": "create:block/belt_observer/eject_belt", "y": 270 }, + "mode=eject,powered=false,belt=true,facing=north": { "model": "create:block/belt_observer/eject_belt", "y": 180 }, + "mode=eject,powered=false,belt=true,facing=west": { "model": "create:block/belt_observer/eject_belt", "y": 90 }, + + "mode=eject,powered=true,belt=true,facing=south": { "model": "create:block/belt_observer/eject_belt_powered", "y": 0 }, + "mode=eject,powered=true,belt=true,facing=east": { "model": "create:block/belt_observer/eject_belt_powered", "y": 270 }, + "mode=eject,powered=true,belt=true,facing=north": { "model": "create:block/belt_observer/eject_belt_powered", "y": 180 }, + "mode=eject,powered=true,belt=true,facing=west": { "model": "create:block/belt_observer/eject_belt_powered", "y": 90 }, + + + "mode=split,powered=false,belt=false,facing=south": { "model": "create:block/belt_observer/split", "y": 0 }, + "mode=split,powered=false,belt=false,facing=east": { "model": "create:block/belt_observer/split", "y": 270 }, + "mode=split,powered=false,belt=false,facing=north": { "model": "create:block/belt_observer/split", "y": 180 }, + "mode=split,powered=false,belt=false,facing=west": { "model": "create:block/belt_observer/split", "y": 90 }, + + "mode=split,powered=true,belt=false,facing=south": { "model": "create:block/belt_observer/split_powered", "y": 0 }, + "mode=split,powered=true,belt=false,facing=east": { "model": "create:block/belt_observer/split_powered", "y": 270 }, + "mode=split,powered=true,belt=false,facing=north": { "model": "create:block/belt_observer/split_powered", "y": 180 }, + "mode=split,powered=true,belt=false,facing=west": { "model": "create:block/belt_observer/split_powered", "y": 90 }, + + "mode=split,powered=false,belt=true,facing=south": { "model": "create:block/belt_observer/split_belt", "y": 0 }, + "mode=split,powered=false,belt=true,facing=east": { "model": "create:block/belt_observer/split_belt", "y": 270 }, + "mode=split,powered=false,belt=true,facing=north": { "model": "create:block/belt_observer/split_belt", "y": 180 }, + "mode=split,powered=false,belt=true,facing=west": { "model": "create:block/belt_observer/split_belt", "y": 90 }, + + "mode=split,powered=true,belt=true,facing=south": { "model": "create:block/belt_observer/split_belt_powered", "y": 0 }, + "mode=split,powered=true,belt=true,facing=east": { "model": "create:block/belt_observer/split_belt_powered", "y": 270 }, + "mode=split,powered=true,belt=true,facing=north": { "model": "create:block/belt_observer/split_belt_powered", "y": 180 }, + "mode=split,powered=true,belt=true,facing=west": { "model": "create:block/belt_observer/split_belt_powered", "y": 90 } } } \ No newline at end of file diff --git a/src/main/resources/assets/create/lang/en_us.json b/src/main/resources/assets/create/lang/en_us.json index 4754ecdb3..746143f91 100644 --- a/src/main/resources/assets/create/lang/en_us.json +++ b/src/main/resources/assets/create/lang/en_us.json @@ -953,11 +953,15 @@ "block.create.brass_casing.tooltip.behaviour1": "_Reinforces_ _belts_ with a brass foundation. Reinforced Belts can support _Belt_ _Tunnels_ aswell as _Extractors,_ _Funnels_ and _Transposers_ interacting with the belt from the sides and below.", "block.create.entity_detector.tooltip": "BELT OBSERVER", - "block.create.entity_detector.tooltip.summary": "Detects items passing by on a _Mechanical_ _Belt_ in front of it. Works well with a _Piston_ on top, pushing certain items off.", - "block.create.entity_detector.tooltip.condition1": "When item matches Filter", - "block.create.entity_detector.tooltip.behaviour1": "Provides a short _Redstone_ _pulse_ to all sides. An Empty Filter matches all passing items.", - "block.create.entity_detector.tooltip.control1": "R-Click on Filter Space", - "block.create.entity_detector.tooltip.action1": "Assigns currently _held_ _stack_ as the _Filter._ Observer will react to this item type only.", + "block.create.entity_detector.tooltip.summary": "Detects items and entities passing by on a _Mechanical_ _Belt_ in front of it. Use a _Wrench_ to cycle its behaviour. Non-items will always be handled in detect mode regarless of the setting.", + "block.create.entity_detector.tooltip.condition1": "Detect Mode", + "block.create.entity_detector.tooltip.behaviour1": "Provides redstone _while_ a _matching_ _item_ _is_ in the observed belt segment.", + "block.create.entity_detector.tooltip.condition2": "Pulse Mode", + "block.create.entity_detector.tooltip.behaviour2": "Emits a _pulse_ when a _matching_ _item_ _passes_ the center of the observed belt segment.", + "block.create.entity_detector.tooltip.condition3": "Eject Mode", + "block.create.entity_detector.tooltip.behaviour3": "_Ejects_ _matching_ _items_ off the side. If the target belt or space is _occupied,_ the item will be _held_ _in_ _place._", + "block.create.entity_detector.tooltip.condition4": "Split Mode", + "block.create.entity_detector.tooltip.behaviour4": "_Splits_ a _matching_ _item_ _stack_ and _ejects_ _half_ of it off the side.", "block.create.pulse_repeater.tooltip": "PULSE REPEATER", "block.create.pulse_repeater.tooltip.summary": "A simple circuit for cutting passing redstone signals to a length of _1_ _tick._", diff --git a/src/main/resources/assets/create/models/block/entity_detector.json b/src/main/resources/assets/create/models/block/belt_observer/base.json similarity index 96% rename from src/main/resources/assets/create/models/block/entity_detector.json rename to src/main/resources/assets/create/models/block/belt_observer/base.json index 707f404f5..32c14f1ba 100644 --- a/src/main/resources/assets/create/models/block/entity_detector.json +++ b/src/main/resources/assets/create/models/block/belt_observer/base.json @@ -4,9 +4,9 @@ "textures": { "brass_casing": "create:block/brass_casing", "extractor": "create:block/extractor", - "particle": "create:block/entity_detector_off", - "entity_detector_off": "create:block/entity_detector_off", - "entity_detector_front": "create:block/entity_detector_front" + "particle": "#texture", + "entity_detector_off": "#texture", + "entity_detector_front": "create:block/belt_observer_front" }, "elements": [ { diff --git a/src/main/resources/assets/create/models/block/entity_detector_with_belt.json b/src/main/resources/assets/create/models/block/belt_observer/base_belt.json similarity index 96% rename from src/main/resources/assets/create/models/block/entity_detector_with_belt.json rename to src/main/resources/assets/create/models/block/belt_observer/base_belt.json index 1e1e00118..baed95503 100644 --- a/src/main/resources/assets/create/models/block/entity_detector_with_belt.json +++ b/src/main/resources/assets/create/models/block/belt_observer/base_belt.json @@ -4,9 +4,9 @@ "textures": { "3": "create:block/extractor", "brass_casing": "create:block/brass_casing", - "particle": "create:block/entity_detector_off", - "entity_detector_off": "create:block/entity_detector_off", - "entity_detector_front": "create:block/entity_detector_front" + "particle": "#texture", + "entity_detector_off": "#texture", + "entity_detector_front": "create:block/belt_observer_front" }, "elements": [ { diff --git a/src/main/resources/assets/create/models/block/belt_observer/base_belt_powered.json b/src/main/resources/assets/create/models/block/belt_observer/base_belt_powered.json new file mode 100644 index 000000000..a81d7492c --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/base_belt_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_belt", + "textures": { + "3": "create:block/extractor_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/base_powered.json b/src/main/resources/assets/create/models/block/belt_observer/base_powered.json new file mode 100644 index 000000000..17177a585 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/base_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base", + "textures": { + "extractor": "create:block/extractor_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/detect.json b/src/main/resources/assets/create/models/block/belt_observer/detect.json new file mode 100644 index 000000000..5a6ba1150 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/detect.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base", + "textures": { + "texture": "create:block/belt_observer_detect" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/detect_belt.json b/src/main/resources/assets/create/models/block/belt_observer/detect_belt.json new file mode 100644 index 000000000..90dcf7aed --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/detect_belt.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_belt", + "textures": { + "texture": "create:block/belt_observer_detect" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/detect_belt_powered.json b/src/main/resources/assets/create/models/block/belt_observer/detect_belt_powered.json new file mode 100644 index 000000000..d941db520 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/detect_belt_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_belt_powered", + "textures": { + "texture": "create:block/belt_observer_detect_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/detect_powered.json b/src/main/resources/assets/create/models/block/belt_observer/detect_powered.json new file mode 100644 index 000000000..a2a3a4bb9 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/detect_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_powered", + "textures": { + "texture": "create:block/belt_observer_detect_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/eject.json b/src/main/resources/assets/create/models/block/belt_observer/eject.json new file mode 100644 index 000000000..821e2c378 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/eject.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base", + "textures": { + "texture": "create:block/belt_observer_eject" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/eject_belt.json b/src/main/resources/assets/create/models/block/belt_observer/eject_belt.json new file mode 100644 index 000000000..4f590d91a --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/eject_belt.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_belt", + "textures": { + "texture": "create:block/belt_observer_eject" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/eject_belt_powered.json b/src/main/resources/assets/create/models/block/belt_observer/eject_belt_powered.json new file mode 100644 index 000000000..d4656f309 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/eject_belt_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_belt_powered", + "textures": { + "texture": "create:block/belt_observer_eject_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/eject_powered.json b/src/main/resources/assets/create/models/block/belt_observer/eject_powered.json new file mode 100644 index 000000000..c7fd5ec96 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/eject_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_powered", + "textures": { + "texture": "create:block/belt_observer_eject_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/pulse.json b/src/main/resources/assets/create/models/block/belt_observer/pulse.json new file mode 100644 index 000000000..39d8c5ef3 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/pulse.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base", + "textures": { + "texture": "create:block/belt_observer_pulse" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/pulse_belt.json b/src/main/resources/assets/create/models/block/belt_observer/pulse_belt.json new file mode 100644 index 000000000..b93de0c5b --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/pulse_belt.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_belt", + "textures": { + "texture": "create:block/belt_observer_pulse" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/pulse_belt_powered.json b/src/main/resources/assets/create/models/block/belt_observer/pulse_belt_powered.json new file mode 100644 index 000000000..7d7bb923f --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/pulse_belt_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_belt_powered", + "textures": { + "texture": "create:block/belt_observer_pulse_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/pulse_powered.json b/src/main/resources/assets/create/models/block/belt_observer/pulse_powered.json new file mode 100644 index 000000000..93c6da0a7 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/pulse_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_powered", + "textures": { + "texture": "create:block/belt_observer_pulse_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/split.json b/src/main/resources/assets/create/models/block/belt_observer/split.json new file mode 100644 index 000000000..12405d396 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/split.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base", + "textures": { + "texture": "create:block/belt_observer_split" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/split_belt.json b/src/main/resources/assets/create/models/block/belt_observer/split_belt.json new file mode 100644 index 000000000..bc413b344 --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/split_belt.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_belt", + "textures": { + "texture": "create:block/belt_observer_split" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/split_belt_powered.json b/src/main/resources/assets/create/models/block/belt_observer/split_belt_powered.json new file mode 100644 index 000000000..2fad9a1bb --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/split_belt_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_belt_powered", + "textures": { + "texture": "create:block/belt_observer_split_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/belt_observer/split_powered.json b/src/main/resources/assets/create/models/block/belt_observer/split_powered.json new file mode 100644 index 000000000..5d373467f --- /dev/null +++ b/src/main/resources/assets/create/models/block/belt_observer/split_powered.json @@ -0,0 +1,6 @@ +{ + "parent": "create:block/belt_observer/base_powered", + "textures": { + "texture": "create:block/belt_observer_split_powered" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/entity_detector_powered.json b/src/main/resources/assets/create/models/block/entity_detector_powered.json deleted file mode 100644 index 51b3e02a6..000000000 --- a/src/main/resources/assets/create/models/block/entity_detector_powered.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "create:block/entity_detector", - "textures": { - "extractor": "create:block/extractor_powered", - "entity_detector_off": "create:block/entity_detector_on", - "particle": "create:block/entity_detector_on" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/entity_detector_with_belt_powered.json b/src/main/resources/assets/create/models/block/entity_detector_with_belt_powered.json deleted file mode 100644 index 9c93843fa..000000000 --- a/src/main/resources/assets/create/models/block/entity_detector_with_belt_powered.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "parent": "create:block/entity_detector_with_belt", - "textures": { - "3": "create:block/extractor_powered", - "entity_detector_off": "create:block/entity_detector_on", - "particle": "create:block/entity_detector_on" - } -} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/item/entity_detector.json b/src/main/resources/assets/create/models/item/entity_detector.json index dba31f41f..c00967dc9 100644 --- a/src/main/resources/assets/create/models/item/entity_detector.json +++ b/src/main/resources/assets/create/models/item/entity_detector.json @@ -15,8 +15,8 @@ }, "textures": { "brass_casing": "create:block/brass_casing", - "entity_detector_off": "create:block/entity_detector_off", - "entity_detector_front": "create:block/entity_detector_front" + "entity_detector_off": "create:block/belt_observer_detect", + "entity_detector_front": "create:block/belt_observer_front" }, "elements": [ { diff --git a/src/main/resources/assets/create/textures/block/belt_observer_detect.png b/src/main/resources/assets/create/textures/block/belt_observer_detect.png new file mode 100644 index 0000000000000000000000000000000000000000..52b6b91800cab83c41391c991f4b9e2f4b3e4c26 GIT binary patch literal 518 zcmV+h0{Q)kP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0h>ugK~y+TZBn~V z!$1(c_4yGyiGl-xkP<~AR7jK*^i-74(I7fLgRek*2meAxhlG?6qB!S!*vw^-i2|e3 zc)UAz-rX}j+#ZWHq9|bTFN~>J(9823E1*!$bD^@V1%_7It}~*)(*b8KNtdSw^QA7d z%VLQTDO*~9SQ7dVLfcq!WYCMf;o_u^$Mki&S5aGtt`IXpxv1ZT7;b2!7L(kXI%vlc zHo%<-f_otZ9ALN`jnrFE!v@g#I7dBDToUwFNf1p0g09YnVH|wS)u7ixl(G40b)}s@ zeyL5K#`0*tO|?iPsdV*OXsQW}T9t9o#?~?*UhrV29Q6}roeY9lBI?VCr7Vrx?Ii4j z2_N_>4Q$3$bTaY-=8Dlq(*uL!K$H6E0imYWEcM<01q`#5mXpH{sz)0D*TBsbrN!cw zm{F3y2ON*;aW)nXz```J8TZ3i1m*}v6h`#h!`3}CLB6FXNKcQ~#+oRMqL2!u9R??f z8R;xdz{RQr_qyqPv7-B%@j4NL0ay9KgQ59{uQ1m2D^Qm18|=~n@H)-RPyhe`07*qo IM6N<$f{QKU!vFvP literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/create/textures/block/belt_observer_detect_powered.png b/src/main/resources/assets/create/textures/block/belt_observer_detect_powered.png new file mode 100644 index 0000000000000000000000000000000000000000..af9a00ace622a6cee316fab43095584943a04e81 GIT binary patch literal 507 zcmVPx#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0gy>VK~y+Tg;Kjt z!$1(cz4JM-6BH8OX^;>Sq(Y*gprEIsgpLN$AU=anphA2H-$F@=C;~*-=X==9Wl@L( zh|y^@p4&Umu1(kHJ7Nm0C5vC-T+M`12nkAHK#|r;k8Yg-?f}|Fk;pk%s^P002ovPDHLkV1i?2-^&01 literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/create/textures/block/belt_observer_eject.png b/src/main/resources/assets/create/textures/block/belt_observer_eject.png new file mode 100644 index 0000000000000000000000000000000000000000..bfc4beaef82858b5d54f3875e1e24188d55e8bfe GIT binary patch literal 532 zcmV+v0_**WP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0jWtuK~y+TZIZoi z)Ibo&cf7Xm?Bo<2357(Wi^QdhL`gwUMF|}ZqT?}m3dD2pD)bSgNO9a9{#tvz{Prd? zS1=m=HS?d@osV7l{NaT;NR}mP{8xryQbWFf`=}PubUtF!mE{t|?%a5YnDZy6V7avN z_T@9@LvAI_A1gd;yImdgE~}y}tdhv+riWc`*O#X@5zY)_)ZdLGdwsWG?A)(B@zW$h zB$&yEP3saX38|c>0$RI4v-ifVjJde`gS)Mr=2S&K4nbaBSB;CUBmFqt-q#x=l?j}w zjX5#q=kpaj(M6hI#2M(GzMq~go7UfNS`BLk$Rz4gpCa<+_JU^csS9=WV>92axL;Q% zc{bzi{drSwd^jhzf3&0-QEaOUOaDlS;7m$_x0xg|t-WDY&f0L7Yh8^^mp782NO ze231l>`3t-C@!zj^drh6U@LZ`r_Y4zwR@BcP;HmiwR=z*R>V~QW}r)q;~A9HSDH!r z`sLj)4q2LIsWhGQK3FS?gv(+9Hf;}{t%~iwl~3=l4}la!{1g}i#MTebFH#rjd;b?s W&=7BHdThJ^0000Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0m(^3K~y+TZBn~# z6G0TccV~CwT^t2R1PDcFA|OH{QVL3Hs3@U8qCs?g0Sygb5#>Ab4>UB9B2fhz6gif$ z{#2n9)O`+7y1Zo z-yVYNf#TOk_gze-;=Ei|7|(1S6BMq>x>DiRLXjOWChsEuiAT&6g~QQSra$c^*J{rPPCljtGQyR$LO*^QGkqpA!(sk@uy)wP>x z51E_r>|&1To)Y2CC6Srfi(xrgILN|=MH9Oj&^`Lz*&1jQe@{&lmJ8X)yQy|Zm6)iH zBK+#`9-4uTy2-e`AJdn8?&n0`h`tm3dNjiHt26xKU>n-4vVcqOAPnwu_J9dS`lWgB zpj)t1uS=y}T(tyPx#1ZP1_K>z@;j|==^1poj532;bRa{vGi!2kdb!2!6DYwZ940kTO%K~y+TZIaJU z+dvS;cXs_Jb`sKn5PziJkP0Uxj(vlkdTejKRK4*SJO$!8cpwBEs6><0j=lEU{G35F zsu-<4eLFL|GxP1r<&RHhV{vSiylYL29GB5qmI###c`D5{HWNv!S z6vm8=x&JuDPc)4zWSD{O>3e@Rdi=fSu!c1Q+!;sXB!*C*BJ$<@fM(cJ7Z)**(orm$ zr%^R>-0^N&wZU0S0K}U(S2tmAk|Kuc!3fK`A*~6WoE;AWYxO*F+bv=0$KFD(GvGpI zRbyNGZ6g6?hj*wvVh=9ufi165)-8)ifGg4xvstdEd+ug&0gItI%)~mh$^bzkl=wFT zT|)koRa=L@IpzB58!E<897j@CJ|LVEMZ$TOg5|mfXVYx4TFbBRC!0V7Vxj991BB~` f=NIV~tLyLryh0cvqU3~&00000NkvXXu0mjf^Pu;- literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/create/textures/block/belt_observer_pulse_powered.png b/src/main/resources/assets/create/textures/block/belt_observer_pulse_powered.png new file mode 100644 index 0000000000000000000000000000000000000000..e0872d4b2b209f1b25c15a44e6a3f68c9f879a5d GIT binary patch literal 560 zcmV-00?+-4P)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!2kdb!2!6DYwZ940mVr~K~y+TZIU}~ z6hRP%yQgPncgAaM4Cdj4#1dFYAo&(Vgb*N+ATmxsLc%E!=inlioFRx1+FhA_Fw@T& zzS&xt6{6JoRb5rxRsY|u-@SgQHdYjwIRCW}I&t)u&u_%T8k+`eY+a8*eCy*TqmB+I zU_Cba`T0Gc`qJpU+;*5QY@K=>U6plZB#1@dO_$C*x<4_Q=1hpg`qlW`#(cP(pU&;& zaXo8;?zQe!m-?&LXGUj~a+(fY_S*;Uet$9juG9miUR_Mt5|o;oRT)EX?(CPdm0vXB zYUP)0eDZAxyT?j#=BHBa+PPF9)W?`A1e69sfG0KYe_GibY-&xo)ga2xqh)>AD($P3ype y{c5pl_1l-Hn?w#`sq3Ku;>(BU7s(cLF8u+O@gM{F+0Od_0000Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0m4Z{K~y+TZIVll z(?Af0yWO@EI|-Qwnqg+c28lsJLgE&zW;yKGAa)#sQy|X4b&y7YL=YiPV!K~9pIxJX zMwD8m@?Vdx|8MK}Z=R~rvMiC{zvg`>f&TpItwdPe#=+NZSx)i9tqWsDogB^a<<#iw zmycZRbEDIIxM8(vt9^L0awzts9pZolr_QH|(94>g_nMc5$K9`RxvHvv(lJMIL-_&KCL4t=rVT zYQpocyS36wrPj;o&c@l!H%gsW?$$61RgXu#`<_VpCE?l0nN&K%6#nfv&%tX zxw_2Fy{!bt4yij1K*%hL9fZGU6rk+z4y{A!0g@f~Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0m4Z{K~y+TZIZig z)j$x2cfG#E&IyokPeX&mr9pzHprV8Vi3X+P38?cFi09xT=uoN@NR;Rh8K2AAyX&?2 z?1>H$Vze6l`_JrLep`Qd_ejl_Wr=|QS_p#x{pIs}L7460}+xpGqy*@SHy$-ZUG>3QuouG#vN z^SX=!B&nRb^=YOPQsoVmsQvM5`D3n!Jy7cH*%DH64$Hg`qq%dC|62RThI;Lves69o z^;4;@hh=TUi?s*07u`3bFE)PD^&1zb9hjcJ)L3nM*I%k3R;1I+*Y?x>Jlpy}6aDhp zUFLzMFO&pm&A4EAiHeb9j*p72k0wb7;9+xPT!=Rpg-Kv0Jy>Do0%;)*`pNMmu(Ymn zV|~0jmGIaubh!f*!igF?;r}sF);zwy==`9kOeHgL{cXK#1QidmXvskWVu2xqi-!c|$|ZR_yY56WiU v>XSDQ=Rk_b;xMuX9xOlnfUNTsb1wb?R<0nuY(zXD00000NkvXXu0mjf&Z+~1 literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/create/textures/block/clutch_off.png b/src/main/resources/assets/create/textures/block/clutch_off.png index 986a4400223a508db125d40f3cd806388bf23023..2988f8b8f0d95477d33b57520ec268b3b6f2de04 100644 GIT binary patch delta 498 zcmVMjuA>FQjRz71wp48&(O2ua1@}FPCk&*Xu%vv|elEQre7v z!4gKH>orTPuuG+z+s`Tp`1bJ%>^N0$)1e7hZ1Bhx_uid@Eqr#x1;07iJ>K^Yy0vG` zn&xVy4Ax5oR9y#0QV9>^JM6tkGRTSxBXAkT6jTXqzq5USzk!^H6Z&lVEtLRF7t5cs z_&((0NK7ITB}$;opTzfR2;qF0uHrC%2vyVQ;nVfkPQg5)I#EE(CpjV7+tT40yzh+f z#}=yOs}#`=F+|5ihyWwn=y3h8q@In9D)_xU8}79|DJfr*BsG4GqL5jhTNaCx750Ti zRd6eH^nek?%Pi%83`%5~loGdzrZp^7z<|3Ab!Gp@JeY0nL8Ic7Ax1IM@OHpmus?tC z5?t!P?$_!qG5s=G2$_pnvJMlmE%P`7Bh>Gm1i>$Mad|N~9pX}80vdh`tozf@E*u+- o$G3Uj`Z42(V6z0Y#Vm>FH|)Oy66YV7tpET307*qoM6N<$f(o7KPXGV_ delta 378 zcmV-=0fqjf1gZm&B#|)~f4~3$4!{9w)`|>&L;1 zP_RTRDQitiPyNY#mUr1`upm4P@6P0%-I?^pPvbwaxfRkedPBWze`eL(eJ`MLuAG%* zTvHR_t(;bini3jMFxcS$iY$TG%Mc^V(=-@X>os35A5(C}apc_|M2&&I;YpL}gfr!B zVBntCfa2WwsDqwF>vo2l)7`t#K85=%dAaZ)p3f7F2YelFV1~VZ@5GqQm@8w>%np&` zPff}9WoUdTQmV-#aHNTp=;(K&E#YAXR@6MCU&XIQ&2Q6>>%-6dNJEDk{DOyr&XgUr z*7nE!XG`tSGUyG|;(LVtCI)8k25#X=7)U8@gTBFl!Xsz{WFpE-hZz6`((xEG@o00q Y0nPx#1ZP1_K>z@;j|==^1poj532;bRa{vGi!T8!inuT;qy)v zR*2DP^m{z^{QubU?&68rSydGZ{%bLg3gpwrOGTLLQ;x20+a(d)hhev4jvlOt?b6Dt z7Y{?4YAa=Z-@$ch^ZCa&W18ouZDTcw4Pm^x_4etbl`VubamfD5g_AEo?~FM%ru*); z>ry6>$&6{b=|W+ppp?^ez<-B${q_3B$l4grcr&pisWpd9J;X^~o*%l9ske3R4)#OV zw(_fw2mSg-1MPAj`SAXA z9AZ^gRVl6yiNRUX$adQ-h_3U*&AQp%b@KMj`EH{mVrk5SCxZ3E^NVzed7u6OI%yg< Td*jzN00000NkvXXu0mjf7M$~Q diff --git a/src/main/resources/assets/create/textures/block/entity_detector_on.png b/src/main/resources/assets/create/textures/block/entity_detector_on.png deleted file mode 100644 index 7065ec314371957d22190658e3832f793052bca3..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 544 zcmV+*0^j|KP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!TjSI^aFw%=h{Vf-}LQ-D5-q0=l+0E=$h|8}VG*ny!f@^0_R({$Z%8anbhZOGF{`mEP?vIFj zeO>24WYmc^c8`tAB*~r46>Q)L+I{%_2(e#;z@9rHng=r<6|Iz5t(06efev=Z+9m0A zA;DyV4ar}bCxysEA^QrF`ty0PHVYBhgu==5lJxsZc_*rvgQ ik@F9azlc8pYvW%fs1je)l?SW<0000