Search in sources :

Example 1 with ToolItem

use of net.minecraft.item.ToolItem in project minecolonies by Minecolonies.

the class WorkerUtil method getBestToolForBlock.

/**
 * Get a Tooltype for a certain block. We need this because minecraft has a lot of blocks which have strange or no required tool.
 *
 * @param state         the target BlockState.
 * @param blockHardness the hardness.
 * @return the toolType to use.
 */
public static IToolType getBestToolForBlock(final BlockState state, float blockHardness) {
    final net.minecraftforge.common.ToolType forgeTool = state.getHarvestTool();
    String toolName = "";
    if (forgeTool == null) {
        if (blockHardness > 0f) {
            for (final Tuple<ToolType, ItemStack> tool : getOrInitTestTools()) {
                if (tool.getB() != null && tool.getB().getItem() instanceof ToolItem) {
                    final ToolItem toolItem = (ToolItem) tool.getB().getItem();
                    if (tool.getB().getDestroySpeed(state) >= toolItem.getTier().getSpeed()) {
                        toolName = tool.getA().getName();
                        break;
                    }
                }
            }
        }
    } else {
        toolName = forgeTool.getName();
    }
    final IToolType toolType = ToolType.getToolType(toolName);
    if (toolType == ToolType.NONE && state.getMaterial() == Material.WOOD) {
        return ToolType.AXE;
    } else if (state.getBlock() instanceof GlazedTerracottaBlock) {
        return ToolType.PICKAXE;
    }
    return toolType;
}
Also used : GlazedTerracottaBlock(net.minecraft.block.GlazedTerracottaBlock) IToolType(com.minecolonies.api.util.constant.IToolType) ToolType(com.minecolonies.api.util.constant.ToolType) IToolType(com.minecolonies.api.util.constant.IToolType) ItemStack(net.minecraft.item.ItemStack) ToolItem(net.minecraft.item.ToolItem)

Example 2 with ToolItem

use of net.minecraft.item.ToolItem in project BleachHack by BleachDrinker420.

the class AutoArmor method onTick.

@BleachSubscribe
public void onTick(EventTick event) {
    if (mc.player.playerScreenHandler != mc.player.currentScreenHandler || !BleachQueue.isEmpty("autoarmor_equip"))
        return;
    if (tickDelay > 0) {
        tickDelay--;
        return;
    }
    tickDelay = (getSetting(2).asToggle().getState() ? getSetting(2).asToggle().getChild(0).asSlider().getValueInt() : 0);
    /* [Slot type, [Armor slot, Armor prot, New armor slot, New armor prot]] */
    Map<EquipmentSlot, int[]> armorMap = new HashMap<>(4);
    armorMap.put(EquipmentSlot.FEET, new int[] { 36, getProtection(mc.player.getInventory().getStack(36)), -1, -1 });
    armorMap.put(EquipmentSlot.LEGS, new int[] { 37, getProtection(mc.player.getInventory().getStack(37)), -1, -1 });
    armorMap.put(EquipmentSlot.CHEST, new int[] { 38, getProtection(mc.player.getInventory().getStack(38)), -1, -1 });
    armorMap.put(EquipmentSlot.HEAD, new int[] { 39, getProtection(mc.player.getInventory().getStack(39)), -1, -1 });
    /* Anti Break */
    if (getSetting(0).asToggle().getState()) {
        for (Entry<EquipmentSlot, int[]> e : armorMap.entrySet()) {
            ItemStack is = mc.player.getInventory().getStack(e.getValue()[0]);
            int armorSlot = (e.getValue()[0] - 34) + (39 - e.getValue()[0]) * 2;
            if (is.isDamageable() && is.getMaxDamage() - is.getDamage() < 7) {
                /* Look for an empty slot to quick move to */
                int forceMoveSlot = -1;
                for (int s = 0; s < 36; s++) {
                    if (mc.player.getInventory().getStack(s).isEmpty()) {
                        mc.interactionManager.clickSlot(mc.player.currentScreenHandler.syncId, armorSlot, 1, SlotActionType.QUICK_MOVE, mc.player);
                        return;
                    } else if (!(mc.player.getInventory().getStack(s).getItem() instanceof ToolItem) && !(mc.player.getInventory().getStack(s).getItem() instanceof ArmorItem) && !(mc.player.getInventory().getStack(s).getItem() instanceof ElytraItem) && mc.player.getInventory().getStack(s).getItem() != Items.TOTEM_OF_UNDYING && forceMoveSlot == -1) {
                        forceMoveSlot = s;
                    }
                }
                /* Bruh no empty spots, then force move to a non-totem/tool/armor item */
                if (forceMoveSlot != -1) {
                    // System.out.println(forceMoveSlot);
                    mc.interactionManager.clickSlot(mc.player.currentScreenHandler.syncId, forceMoveSlot < 9 ? 36 + forceMoveSlot : forceMoveSlot, 1, SlotActionType.THROW, mc.player);
                    mc.interactionManager.clickSlot(mc.player.currentScreenHandler.syncId, armorSlot, 1, SlotActionType.QUICK_MOVE, mc.player);
                    return;
                }
                /* No spots to move to, yeet the armor to not cause any bruh moments */
                mc.interactionManager.clickSlot(mc.player.currentScreenHandler.syncId, armorSlot, 1, SlotActionType.THROW, mc.player);
                return;
            }
        }
    }
    for (int s = 0; s < 36; s++) {
        int prot = getProtection(mc.player.getInventory().getStack(s));
        if (prot > 0) {
            EquipmentSlot slot = (mc.player.getInventory().getStack(s).getItem() instanceof ElytraItem ? EquipmentSlot.CHEST : ((ArmorItem) mc.player.getInventory().getStack(s).getItem()).getSlotType());
            for (Entry<EquipmentSlot, int[]> e : armorMap.entrySet()) {
                if (e.getKey() == slot) {
                    if (prot > e.getValue()[1] && prot > e.getValue()[3]) {
                        e.getValue()[2] = s;
                        e.getValue()[3] = prot;
                    }
                }
            }
        }
    }
    for (Entry<EquipmentSlot, int[]> e : armorMap.entrySet()) {
        if (e.getValue()[2] != -1) {
            if (e.getValue()[1] == -1 && e.getValue()[2] < 9) {
                if (e.getValue()[2] != mc.player.getInventory().selectedSlot) {
                    mc.player.getInventory().selectedSlot = e.getValue()[2];
                    mc.player.networkHandler.sendPacket(new UpdateSelectedSlotC2SPacket(e.getValue()[2]));
                }
                mc.interactionManager.clickSlot(mc.player.currentScreenHandler.syncId, 36 + e.getValue()[2], 1, SlotActionType.QUICK_MOVE, mc.player);
            } else if (mc.player.playerScreenHandler == mc.player.currentScreenHandler) {
                /* Convert inventory slots to container slots */
                int armorSlot = (e.getValue()[0] - 34) + (39 - e.getValue()[0]) * 2;
                int newArmorslot = e.getValue()[2] < 9 ? 36 + e.getValue()[2] : e.getValue()[2];
                mc.interactionManager.clickSlot(mc.player.currentScreenHandler.syncId, newArmorslot, 0, SlotActionType.PICKUP, mc.player);
                mc.interactionManager.clickSlot(mc.player.currentScreenHandler.syncId, armorSlot, 0, SlotActionType.PICKUP, mc.player);
                if (e.getValue()[1] != -1)
                    mc.interactionManager.clickSlot(mc.player.currentScreenHandler.syncId, newArmorslot, 0, SlotActionType.PICKUP, mc.player);
            }
            return;
        }
    }
}
Also used : ArmorItem(net.minecraft.item.ArmorItem) HashMap(java.util.HashMap) UpdateSelectedSlotC2SPacket(net.minecraft.network.packet.c2s.play.UpdateSelectedSlotC2SPacket) EquipmentSlot(net.minecraft.entity.EquipmentSlot) ElytraItem(net.minecraft.item.ElytraItem) ItemStack(net.minecraft.item.ItemStack) ToolItem(net.minecraft.item.ToolItem) BleachSubscribe(org.bleachhack.eventbus.BleachSubscribe)

Example 3 with ToolItem

use of net.minecraft.item.ToolItem in project minecolonies by ldtteam.

the class WorkerUtil method getBestToolForBlock.

/**
 * Get a Tooltype for a certain block. We need this because minecraft has a lot of blocks which have strange or no required tool.
 *
 * @param state         the target BlockState.
 * @param blockHardness the hardness.
 * @return the toolType to use.
 */
public static IToolType getBestToolForBlock(final BlockState state, float blockHardness) {
    final net.minecraftforge.common.ToolType forgeTool = state.getHarvestTool();
    String toolName = "";
    if (forgeTool == null) {
        if (blockHardness > 0f) {
            for (final Tuple<ToolType, ItemStack> tool : getOrInitTestTools()) {
                if (tool.getB() != null && tool.getB().getItem() instanceof ToolItem) {
                    final ToolItem toolItem = (ToolItem) tool.getB().getItem();
                    if (tool.getB().getDestroySpeed(state) >= toolItem.getTier().getSpeed()) {
                        toolName = tool.getA().getName();
                        break;
                    }
                }
            }
        }
    } else {
        toolName = forgeTool.getName();
    }
    final IToolType toolType = ToolType.getToolType(toolName);
    if (toolType == ToolType.NONE && state.getMaterial() == Material.WOOD) {
        return ToolType.AXE;
    } else if (state.getBlock() instanceof GlazedTerracottaBlock) {
        return ToolType.PICKAXE;
    }
    return toolType;
}
Also used : GlazedTerracottaBlock(net.minecraft.block.GlazedTerracottaBlock) IToolType(com.minecolonies.api.util.constant.IToolType) ToolType(com.minecolonies.api.util.constant.ToolType) IToolType(com.minecolonies.api.util.constant.IToolType) ItemStack(net.minecraft.item.ItemStack) ToolItem(net.minecraft.item.ToolItem)

Example 4 with ToolItem

use of net.minecraft.item.ToolItem in project bioplethora by AquexTheSeal.

the class BioItemModelProvider method defaultItem.

/**
 * If Item is ToolItem or SwordItem, minecraft/handheld model will be generated for that item.
 * Otherwise, minecraft/generated model will be generated for that item.
 */
public void defaultItem(Collection<RegistryObject<Item>> items) {
    for (RegistryObject<Item> item : items) {
        String name = item.getId().getPath();
        Item getItem = item.get();
        ResourceLocation datagenLoc = new ResourceLocation(Bioplethora.MOD_ID, "item/" + name);
        ModelFile.ExistingModelFile modelType = getItem instanceof ToolItem || getItem instanceof SwordItem ? getMcLoc("item/handheld") : getMcLoc("item/generated");
        if (!existingFileHelper.exists(datagenLoc, TEXTURE) || existingFileHelper.exists(datagenLoc, MODEL))
            continue;
        this.getBuilder(name).parent(modelType).texture("layer0", ITEM_FOLDER + "/" + name);
        Bioplethora.LOGGER.info("Generate Item Successful: " + item.getId());
    }
}
Also used : Item(net.minecraft.item.Item) ToolItem(net.minecraft.item.ToolItem) SwordItem(net.minecraft.item.SwordItem) ShieldItem(net.minecraft.item.ShieldItem) ModelFile(net.minecraftforge.client.model.generators.ModelFile) ResourceLocation(net.minecraft.util.ResourceLocation) SwordItem(net.minecraft.item.SwordItem) ToolItem(net.minecraft.item.ToolItem)

Example 5 with ToolItem

use of net.minecraft.item.ToolItem in project Hypnotic-Client by Hypnotic-Development.

the class Killaura method onMotionUpdate.

@EventTarget
public void onMotionUpdate(EventMotionUpdate event) {
    if (maxAps.getValue() <= minAps.getValue())
        maxAps.setValue(minAps.getValue() + 1);
    if (event.isPre()) {
        try {
            if (mc.world != null) {
                List<LivingEntity> targets = Lists.<LivingEntity>newArrayList();
                for (Entity e : mc.world.getEntities()) {
                    if (e instanceof LivingEntity && e != mc.player && !FriendManager.INSTANCE.isFriend((LivingEntity) e) && mc.player.distanceTo(e) <= range.getValue() && canAttack((LivingEntity) e))
                        targets.add((LivingEntity) e);
                    else {
                        if (targets.contains(e))
                            targets.remove(e);
                    }
                }
                if (target != null && mc.player.distanceTo(target) > range.getValue()) {
                    targets.remove(target);
                    target = null;
                    if (!ModuleManager.INSTANCE.getModule(Scaffold.class).isEnabled()) {
                        RotationUtils.resetPitch();
                        RotationUtils.resetYaw();
                    }
                }
                switch(mode.getSelected()) {
                    case "Sort":
                        switch(sortMode.getSelected()) {
                            case "Distance":
                                targets.sort(Comparator.comparingDouble(entity -> mc.player.distanceTo(entity)));
                                break;
                            case "Health":
                                targets.sort(Comparator.comparingDouble(entity -> ((LivingEntity) entity).getHealth()));
                                break;
                        }
                        if (!targets.isEmpty()) {
                            if (!FriendManager.INSTANCE.isFriend((LivingEntity) targets.get(0)))
                                target = (LivingEntity) targets.get(0);
                            if (mc.player.distanceTo(target) > range.getValue())
                                target = null;
                            if (target != null) {
                                this.setDisplayName("Killaura " + ColorUtils.gray + (target instanceof PlayerEntity ? target.getName().asString().replaceAll(ColorUtils.colorChar, "&") : target.getDisplayName().asString()));
                                if (canAttack(target)) {
                                    RotationUtils.setSilentPitch(RotationUtils.getRotations(target)[1]);
                                    RotationUtils.setSilentYaw(RotationUtils.getRotations(target)[0]);
                                    if (rotation.is("Lock View")) {
                                        mc.player.setYaw(RotationUtils.getRotations(target)[0]);
                                        mc.player.setPitch(RotationUtils.getRotations(target)[1]);
                                    }
                                    long aps = minAps.getValue() < 20 ? new Random().nextInt((int) (maxAps.getValue() - minAps.getValue())) + (int) minAps.getValue() : 20;
                                    if (delay.isEnabled() && random.isEnabled() && mc.player.getAttackCooldownProgress(0.5F) != 1)
                                        attackTimer.reset();
                                    if (delay.isEnabled() ? mc.player.getAttackCooldownProgress(0.5F) == 1 && (random.isEnabled() ? attackTimer.hasTimeElapsed(new Random().nextInt(300 - 100) + 100, true) : true) : attackTimer.hasTimeElapsed((long) (1000L / aps), true)) {
                                        if (autoBlock.isEnabled() && mc.player.getOffHandStack().getItem() instanceof ShieldItem && (mc.player.getMainHandStack().getItem() instanceof ToolItem || mc.player.getMainHandStack().getItem() == Items.AIR || mc.player.getMainHandStack().getItem() instanceof AxeItem || mc.player.getMainHandStack().getItem() instanceof SwordItem) && autoBlockMode.is("Normal")) {
                                            mc.player.networkHandler.sendPacket(new PlayerActionC2SPacket(PlayerActionC2SPacket.Action.RELEASE_USE_ITEM, BlockPos.ORIGIN, Direction.DOWN));
                                        }
                                        blocking = false;
                                        mc.interactionManager.attackEntity(mc.player, target);
                                        if (swing.isEnabled() && (autoBlock.isEnabled() ? !ModuleManager.INSTANCE.getModule(OldBlock.class).isEnabled() : true) || (ModuleManager.INSTANCE.getModule(OldBlock.class).isEnabled() ? mc.options.getPerspective() != Perspective.FIRST_PERSON : false) && !(mc.player.getMainHandStack().getItem() instanceof SwordItem))
                                            mc.player.swingHand(Hand.MAIN_HAND);
                                        else
                                            mc.player.networkHandler.sendPacket(new HandSwingC2SPacket(Hand.MAIN_HAND));
                                        if (swing.isEnabled() && !(mc.player.getMainHandStack().getItem() instanceof SwordItem) || ModuleManager.INSTANCE.getModule(OldBlock.class).animation.is("Swing"))
                                            mc.player.swingHand(Hand.MAIN_HAND);
                                    }
                                }
                                if (target.isDead()) {
                                    RotationUtils.resetYaw();
                                    RotationUtils.resetPitch();
                                }
                            } else {
                                if (blocking)
                                    mc.options.useKey.setPressed(false);
                                blocking = false;
                                if (!ModuleManager.INSTANCE.getModule(Scaffold.class).isEnabled()) {
                                    RotationUtils.resetPitch();
                                    RotationUtils.resetYaw();
                                }
                                this.setDisplayName("Killaura " + ColorUtils.gray + "None");
                            }
                        } else {
                            if (blocking)
                                mc.options.useKey.setPressed(false);
                            blocking = false;
                            if (!ModuleManager.INSTANCE.getModule(Scaffold.class).isEnabled()) {
                                RotationUtils.resetPitch();
                                RotationUtils.resetYaw();
                            }
                        }
                        break;
                    case "Multi":
                        if (!targets.isEmpty()) {
                            for (LivingEntity entity : targets) {
                                if (entity != null && !FriendManager.INSTANCE.isFriend(entity)) {
                                    this.setDisplayName("Killaura " + ColorUtils.gray + (entity instanceof PlayerEntity ? entity.getName().asString().replaceAll(ColorUtils.colorChar, "&") : entity.getDisplayName().asString()));
                                    if (canAttack(entity)) {
                                        if (target != null)
                                            RotationUtils.setSilentPitch(RotationUtils.getRotations(target)[1]);
                                        if (target != null)
                                            RotationUtils.setSilentYaw(RotationUtils.getRotations(target)[0]);
                                        if (rotation.is("Lock View")) {
                                            if (target != null)
                                                mc.player.setYaw(RotationUtils.getRotations(target)[0]);
                                            if (target != null)
                                                mc.player.setPitch(RotationUtils.getRotations(target)[1]);
                                        }
                                        long aps = minAps.getValue() < 20 ? new Random().nextInt((int) (maxAps.getValue() - minAps.getValue())) + (int) minAps.getValue() : 20;
                                        if (delay.isEnabled() && random.isEnabled() && mc.player.getAttackCooldownProgress(0.5F) != 1)
                                            attackTimer.reset();
                                        if ((delay.isEnabled() ? mc.player.getAttackCooldownProgress(0.5F) == 1 && (random.isEnabled() ? attackTimer.hasTimeElapsed(new Random().nextInt(300 - 100) + 100, true) : true) : attackTimer.hasTimeElapsed((long) (1000L / aps), true)) && targets.indexOf(entity) == new Random().nextInt(targets.size())) {
                                            if (autoBlock.isEnabled() && mc.player.getOffHandStack().getItem() instanceof ShieldItem && (mc.player.getMainHandStack().getItem() instanceof ToolItem || mc.player.getMainHandStack().getItem() == Items.AIR || mc.player.getMainHandStack().getItem() instanceof AxeItem || mc.player.getMainHandStack().getItem() instanceof SwordItem) && autoBlockMode.is("NCP")) {
                                                mc.player.networkHandler.sendPacket(new PlayerActionC2SPacket(PlayerActionC2SPacket.Action.RELEASE_USE_ITEM, BlockPos.ORIGIN, Direction.DOWN));
                                            }
                                            blocking = false;
                                            target = entity;
                                            mc.interactionManager.attackEntity(mc.player, entity);
                                            if (swing.isEnabled() && (autoBlock.isEnabled() ? !ModuleManager.INSTANCE.getModule(OldBlock.class).isEnabled() : true) || (ModuleManager.INSTANCE.getModule(OldBlock.class).isEnabled() ? mc.options.getPerspective() != Perspective.FIRST_PERSON : false) && !(mc.player.getMainHandStack().getItem() instanceof SwordItem))
                                                mc.player.swingHand(Hand.MAIN_HAND);
                                            else
                                                mc.player.networkHandler.sendPacket(new HandSwingC2SPacket(Hand.MAIN_HAND));
                                            if (swing.isEnabled() && !(mc.player.getMainHandStack().getItem() instanceof SwordItem) || ModuleManager.INSTANCE.getModule(OldBlock.class).animation.is("Swing"))
                                                mc.player.swingHand(Hand.MAIN_HAND);
                                        }
                                    }
                                    if (entity.isDead()) {
                                        RotationUtils.resetYaw();
                                        RotationUtils.resetPitch();
                                    }
                                } else {
                                }
                            }
                        } else {
                            if (!ModuleManager.INSTANCE.getModule(Scaffold.class).isEnabled()) {
                                RotationUtils.resetPitch();
                                RotationUtils.resetYaw();
                            }
                        }
                        break;
                }
                if (targets.isEmpty())
                    target = null;
                this.setDisplayName("Killaura " + ColorUtils.gray + mode.getSelected());
            }
        } catch (Exception e) {
            e.printStackTrace();
        }
    } else {
        if (target == null)
            return;
        if (autoBlock.isEnabled() && (mc.player.getMainHandStack().getItem() instanceof ToolItem || mc.player.getMainHandStack().getItem() == Items.AIR || mc.player.getMainHandStack().getItem() instanceof AxeItem || mc.player.getMainHandStack().getItem() instanceof SwordItem) && !autoBlockMode.is("Visual")) {
            mc.interactionManager.interactItem(mc.player, mc.world, Hand.OFF_HAND);
            mc.interactionManager.interactItem(mc.player, mc.world, Hand.MAIN_HAND);
            if (!blocking && autoBlockMode.is("NCP")) {
                mc.player.networkHandler.sendPacket(new PlayerInteractBlockC2SPacket(Hand.MAIN_HAND, new BlockHitResult(new Vec3d(0.0f, 0.0f, 0.0f), Direction.DOWN, new BlockPos(-1, -1, -1), false)));
                blocking = true;
            }
        }
    }
}
Also used : ColorSetting(dev.hypnotic.settings.settingtypes.ColorSetting) Category(dev.hypnotic.module.Category) PlayerMoveC2SPacketAccessor(dev.hypnotic.mixin.PlayerMoveC2SPacketAccessor) RotationUtils(dev.hypnotic.utils.RotationUtils) PlayerActionC2SPacket(net.minecraft.network.packet.c2s.play.PlayerActionC2SPacket) Random(java.util.Random) FriendManager(dev.hypnotic.config.friends.FriendManager) ModuleManager(dev.hypnotic.module.ModuleManager) Direction(net.minecraft.util.math.Direction) EventMotionUpdate(dev.hypnotic.event.events.EventMotionUpdate) Scaffold(dev.hypnotic.module.player.Scaffold) Lists(com.google.common.collect.Lists) EventTarget(dev.hypnotic.event.EventTarget) PlayerInteractBlockC2SPacket(net.minecraft.network.packet.c2s.play.PlayerInteractBlockC2SPacket) Vec3d(net.minecraft.util.math.Vec3d) SwordItem(net.minecraft.item.SwordItem) Hand(net.minecraft.util.Hand) AnimalEntity(net.minecraft.entity.passive.AnimalEntity) NumberSetting(dev.hypnotic.settings.settingtypes.NumberSetting) AxeItem(net.minecraft.item.AxeItem) EventRender3D(dev.hypnotic.event.events.EventRender3D) Entity(net.minecraft.entity.Entity) HandSwingC2SPacket(net.minecraft.network.packet.c2s.play.HandSwingC2SPacket) PassiveEntity(net.minecraft.entity.passive.PassiveEntity) PlayerEntity(net.minecraft.entity.player.PlayerEntity) LivingEntity(net.minecraft.entity.LivingEntity) ArmorStandEntity(net.minecraft.entity.decoration.ArmorStandEntity) ColorUtils(dev.hypnotic.utils.ColorUtils) BlockHitResult(net.minecraft.util.hit.BlockHitResult) BlockPos(net.minecraft.util.math.BlockPos) RenderUtils(dev.hypnotic.utils.render.RenderUtils) Items(net.minecraft.item.Items) OldBlock(dev.hypnotic.module.render.OldBlock) ModeSetting(dev.hypnotic.settings.settingtypes.ModeSetting) HitResult(net.minecraft.util.hit.HitResult) EntityHitResult(net.minecraft.util.hit.EntityHitResult) List(java.util.List) Monster(net.minecraft.entity.mob.Monster) ToolItem(net.minecraft.item.ToolItem) Timer(dev.hypnotic.utils.Timer) Type(net.minecraft.util.hit.HitResult.Type) Mod(dev.hypnotic.module.Mod) PlayerMoveC2SPacket(net.minecraft.network.packet.c2s.play.PlayerMoveC2SPacket) Perspective(net.minecraft.client.option.Perspective) Comparator(java.util.Comparator) EventSendPacket(dev.hypnotic.event.events.EventSendPacket) ShieldItem(net.minecraft.item.ShieldItem) BooleanSetting(dev.hypnotic.settings.settingtypes.BooleanSetting) AnimalEntity(net.minecraft.entity.passive.AnimalEntity) Entity(net.minecraft.entity.Entity) PassiveEntity(net.minecraft.entity.passive.PassiveEntity) PlayerEntity(net.minecraft.entity.player.PlayerEntity) LivingEntity(net.minecraft.entity.LivingEntity) ArmorStandEntity(net.minecraft.entity.decoration.ArmorStandEntity) ShieldItem(net.minecraft.item.ShieldItem) PlayerActionC2SPacket(net.minecraft.network.packet.c2s.play.PlayerActionC2SPacket) HandSwingC2SPacket(net.minecraft.network.packet.c2s.play.HandSwingC2SPacket) SwordItem(net.minecraft.item.SwordItem) AxeItem(net.minecraft.item.AxeItem) Vec3d(net.minecraft.util.math.Vec3d) PlayerEntity(net.minecraft.entity.player.PlayerEntity) LivingEntity(net.minecraft.entity.LivingEntity) OldBlock(dev.hypnotic.module.render.OldBlock) Random(java.util.Random) BlockPos(net.minecraft.util.math.BlockPos) BlockHitResult(net.minecraft.util.hit.BlockHitResult) ToolItem(net.minecraft.item.ToolItem) PlayerInteractBlockC2SPacket(net.minecraft.network.packet.c2s.play.PlayerInteractBlockC2SPacket) EventTarget(dev.hypnotic.event.EventTarget)

Aggregations

ToolItem (net.minecraft.item.ToolItem)5 ItemStack (net.minecraft.item.ItemStack)3 IToolType (com.minecolonies.api.util.constant.IToolType)2 ToolType (com.minecolonies.api.util.constant.ToolType)2 GlazedTerracottaBlock (net.minecraft.block.GlazedTerracottaBlock)2 ShieldItem (net.minecraft.item.ShieldItem)2 SwordItem (net.minecraft.item.SwordItem)2 Lists (com.google.common.collect.Lists)1 FriendManager (dev.hypnotic.config.friends.FriendManager)1 EventTarget (dev.hypnotic.event.EventTarget)1 EventMotionUpdate (dev.hypnotic.event.events.EventMotionUpdate)1 EventRender3D (dev.hypnotic.event.events.EventRender3D)1 EventSendPacket (dev.hypnotic.event.events.EventSendPacket)1 PlayerMoveC2SPacketAccessor (dev.hypnotic.mixin.PlayerMoveC2SPacketAccessor)1 Category (dev.hypnotic.module.Category)1 Mod (dev.hypnotic.module.Mod)1 ModuleManager (dev.hypnotic.module.ModuleManager)1 Scaffold (dev.hypnotic.module.player.Scaffold)1 OldBlock (dev.hypnotic.module.render.OldBlock)1 BooleanSetting (dev.hypnotic.settings.settingtypes.BooleanSetting)1