diff --git a/src/openonyx/features/combat/AntiBot.java b/src/openonyx/features/combat/AntiBot.java new file mode 100644 index 0000000..e852102 --- /dev/null +++ b/src/openonyx/features/combat/AntiBot.java @@ -0,0 +1,112 @@ +package openonyx.features.combat; + +import java.util.HashSet; +import java.util.Iterator; +import java.util.Set; +import meteordevelopment.orbit.EventHandler; +import net.minecraft.client.entity.EntityPlayerSP; +import net.minecraft.client.network.NetHandlerPlayClient; +import net.minecraft.client.network.NetworkPlayerInfo; +import net.minecraft.entity.Entity; +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.scoreboard.ScorePlayerTeam; +import openonyx.configuration.internal.TickEvent; +import openonyx.configuration.internal.WorldChangeEvent; +import openonyx.core.OnyxClient; +import openonyx.features.Module; +import openonyx.features.ModuleCategory; +import openonyx.history.internal.BooleanSetting; + +public class AntiBot extends Module { + public BooleanSetting hideVisuals; + private volatile Set strings; + public BooleanSetting tabCheck = new BooleanSetting("Tab check", false).describe("Also flags any player whose name is absent from the tab list"); + + public static boolean L(EntityPlayer entityPlayer) { + EntityPlayer entityPlayer1 = entityPlayer; + AntiBot antiBot; + if ((antiBot = L()) == null || !antiBot.isEnabled()) { + return false; + } else if (mc.isSingleplayer()) { + return false; + } else if (antiBot.tabCheck.isEnabled() && !antiBot.strings.contains(entityPlayer1.getName())) { + return true; + } else if (entityPlayer1 instanceof EntityPlayerSP) { + return false; + } else { + NetHandlerPlayClient netHandlerPlayClient; + if ((netHandlerPlayClient = mc.getNetHandler()) == null) { + return false; + } else { + NetworkPlayerInfo networkPlayerInfo; + if ((networkPlayerInfo = netHandlerPlayClient.getPlayerInfo(entityPlayer1.getName())) == null) { + return true; + } else if (entityPlayer1.getName().startsWith("§k")) { + return entityPlayer1.isInvisible(); + } else if (networkPlayerInfo.getResponseTime() < 1) { + return true; + } else { + ScorePlayerTeam scorePlayerTeam; + if ((scorePlayerTeam = networkPlayerInfo.getPlayerTeam()) == null) { + return false; + } else { + return !scorePlayerTeam.getRegisteredName().isEmpty() ? false : scorePlayerTeam.getColorPrefix().equals("§c"); + } + } + } + } + } + + public static boolean L(Entity entity) { + Entity entity1 = entity; + AntiBot antiBot; + return (antiBot = L()) == null || !antiBot.isEnabled() || !antiBot.hideVisuals.isEnabled() + ? false + : entity1 instanceof EntityPlayer && L((EntityPlayer)entity1); + } + + public AntiBot() { + super("AntiBot", "Stops the combat modules from targeting bots", ModuleCategory.COMBAT); + this.hideVisuals = new BooleanSetting("Hide visuals", true) + .describe( + "Also keep the render modules off flagged bots - no ESP, glow, chams, boxes, skeleton or name tag on a player the combat modules already ignore" + ); + this.strings = new HashSet<>(); + } + + private static AntiBot L() { + return OnyxClient.moduleManager == null ? null : OnyxClient.moduleManager.antiBot; + } + + @EventHandler + public void onTick(TickEvent tickEvent) { + AntiBot antiBot1 = this; + if (mc.thePlayer != null && mc.getNetHandler() != null) { + HashSet hashSet = new HashSet(); + Iterator iterator; + Iterator iterator1 = iterator = mc.getNetHandler().getPlayerInfoMap().iterator(); + + while (iterator1.hasNext()) { + NetworkPlayerInfo networkPlayerInfo; + if ((networkPlayerInfo = (NetworkPlayerInfo)iterator.next()).getGameProfile().getId().equals(mc.thePlayer.getUniqueID())) { + iterator1 = iterator; + } else { + hashSet.add(networkPlayerInfo.getGameProfile().getName()); + iterator1 = iterator; + } + } + + antiBot1.strings = hashSet; + } + } + + @EventHandler + public void onWorldChange(WorldChangeEvent worldChangeEvent) { + this.strings = new HashSet<>(); + } + + @Override + protected void onDisable() { + this.strings = new HashSet<>(); + } +} diff --git a/src/openonyx/features/combat/AutoBlockMode.java b/src/openonyx/features/combat/AutoBlockMode.java new file mode 100644 index 0000000..dafcc3c --- /dev/null +++ b/src/openonyx/features/combat/AutoBlockMode.java @@ -0,0 +1,14 @@ +package openonyx.features.combat; + +public enum AutoBlockMode { + WATCHDOG, + OFF; + + private static AutoBlockMode[] L() { + AutoBlockMode[] autoBlockModes = new AutoBlockMode[2]; + boolean bl = true; + autoBlockModes[0] = OFF; + autoBlockModes[1] = WATCHDOG; + return autoBlockModes; + } +} diff --git a/src/openonyx/features/combat/AutoBlockTrigger.java b/src/openonyx/features/combat/AutoBlockTrigger.java new file mode 100644 index 0000000..bc10a04 --- /dev/null +++ b/src/openonyx/features/combat/AutoBlockTrigger.java @@ -0,0 +1,16 @@ +package openonyx.features.combat; + +public enum AutoBlockTrigger { + TOGGLE, + ALWAYS, + HOLD; + + private static AutoBlockTrigger[] L() { + AutoBlockTrigger[] autoBlockTriggers = new AutoBlockTrigger[3]; + boolean bl = true; + autoBlockTriggers[0] = ALWAYS; + autoBlockTriggers[1] = HOLD; + autoBlockTriggers[2] = TOGGLE; + return autoBlockTriggers; + } +} diff --git a/src/openonyx/features/combat/BedBreaker.java b/src/openonyx/features/combat/BedBreaker.java new file mode 100644 index 0000000..46af935 --- /dev/null +++ b/src/openonyx/features/combat/BedBreaker.java @@ -0,0 +1,392 @@ +package openonyx.features.combat; + +import meteordevelopment.orbit.EventHandler; +import net.minecraft.block.Block; +import net.minecraft.block.BlockBed; +import net.minecraft.block.BlockBed.EnumPartType; +import net.minecraft.block.state.IBlockState; +import net.minecraft.enchantment.Enchantment; +import net.minecraft.enchantment.EnchantmentHelper; +import net.minecraft.item.ItemPickaxe; +import net.minecraft.item.ItemStack; +import net.minecraft.item.ItemTool; +import net.minecraft.util.AxisAlignedBB; +import net.minecraft.util.BlockPos; +import net.minecraft.util.EnumFacing; +import net.minecraft.util.MovingObjectPosition; +import net.minecraft.util.Vec3; +import net.minecraft.util.MovingObjectPosition.MovingObjectType; +import openonyx.configuration.internal.TickEvent; +import openonyx.configuration.internal.WorldChangeEvent; +import openonyx.core.OnyxClient; +import openonyx.events.GeometryUtils; +import openonyx.events.Rotation; +import openonyx.events.RotationFixMode; +import openonyx.events.RotationManager; +import openonyx.events.RotationMath; +import openonyx.features.Module; +import openonyx.features.ModuleCategory; +import openonyx.history.internal.BooleanSetting; +import openonyx.history.internal.EnumSetting; +import openonyx.history.internal.NumberSetting; +import openonyx.interaction.BlockUtils; +import openonyx.interaction.SwingMode; +import openonyx.utilities.Timer; + +public class BedBreaker extends Module { + private boolean a; + public BooleanSetting prioritizeKillAura; + public NumberSetting range = new NumberSetting("Range", 4.5, 1.0, 6.0, 0.05).withSuffix("m"); + public BooleanSetting ignoreOwnBed; + private BlockPos blockPos; + private int j; + private BlockPos blockPos2; + public BooleanSetting keepRotation; + private BlockPos blockPos3; + public EnumSetting moveFix = new EnumSetting<>("Move fix", RotationFixMode.SILENT) + .describe("Keeps movement consistent with the rotation the server sees"); + private static final long d = 10L; + public EnumSetting swing = new EnumSetting<>("Swing", SwingMode.DO_NOT_HIDE).describe("How the mining swing is shown"); + private static final long f = 400L; + private final Timer timer; + private final Timer timer2; + + private EnumFacing L(BlockPos blockPos, Rotation rotation) { + Vec3 vec3 = GeometryUtils.L(); + Vec3 vec31 = GeometryUtils.L(rotation.yaw(), rotation.pitch()); + double dx = this.range.getFloat() + 1.0; + Vec3 vec32 = vec3.addVector(vec31.xCoord * dx, vec31.yCoord * dx, vec31.zCoord * dx); + MovingObjectPosition movingObjectPosition; + return (movingObjectPosition = mc.theWorld.rayTraceBlocks(vec3, vec32, false, false, false)) != null + && movingObjectPosition.typeOfHit == MovingObjectType.BLOCK + && blockPosx.equals(movingObjectPosition.getBlockPos()) + && movingObjectPosition.sideHit != null + ? movingObjectPosition.sideHit + : this.L(blockPosx); + } + + private BlockPos L(BlockPos blockPos) { + BedBreaker bedBreaker1 = this; + Vec3 vec3 = GeometryUtils.L(); + boolean bl1 = false; + BlockPos blockPos1 = null; + double dx = -1.0; + double e = Double.MAX_VALUE; + boolean bl = false; + BlockPos[] blockPos2x; + int i = (blockPos2x = bedBreaker1.L(blockPosx)).length; + + int jx; + for (int n = jx = 0; n < i; n = ++jx) { + BlockPos blockPos3x = blockPos2x[jx]; + EnumFacing[] enumFacings1 = new EnumFacing[5]; + boolean bl2 = true; + enumFacings1[0] = EnumFacing.UP; + enumFacings1[1] = EnumFacing.NORTH; + enumFacings1[2] = EnumFacing.EAST; + enumFacings1[3] = EnumFacing.SOUTH; + enumFacings1[4] = EnumFacing.WEST; + EnumFacing[] enumFacings = enumFacings1; + int k = enumFacings1.length; + + int l; + for (int m = l = 0; m < k; m = ++l) { + EnumFacing enumFacing = enumFacings[l]; + BlockPos blockPos4 = blockPos3x.offset(enumFacing); + Block block = mc.theWorld.getBlockState(blockPos4).getBlock(); + if (bedBreaker1.L(blockPos4, block)) { + bl1 = true; + } else { + double fx; + if (!(block instanceof BlockBed) && bedBreaker1.L(blockPos4) && !((fx = bedBreaker1.L(blockPos4, block)) <= 0.0)) { + if (blockPos4.equals(bedBreaker1.blockPos3)) { + bl = true; + } + + double g = vec3.squareDistanceTo(GeometryUtils.L(vec3, bedBreaker1.L(blockPos4))); + if (fx > dx || fx == dx && g < e) { + dx = fx; + e = g; + blockPos1 = blockPos4; + } + } + } + } + } + + if (bl1) { + return blockPosx; + } else { + return bl ? bedBreaker1.blockPos3 : blockPos1; + } + } + + private float L(ItemStack itemStack, Block block) { + if (itemStack == null) { + return 1.0F; + } + + float fx = !itemStack.canHarvestBlock(block) && itemStack.getItem() instanceof ItemPickaxe ? 1.0F : itemStack.getStrVsBlock(block); + int i; + if (itemStack.getItem() instanceof ItemTool && fx > 1.0F && (i = EnchantmentHelper.getEnchantmentLevel(Enchantment.efficiency.effectId, itemStack)) > 0) { + fx += i * i + 1; + } + + return fx; + } + + @EventHandler + public void onTick(TickEvent tickEvent) { + BedBreaker bedBreaker1 = this; + if (mc.thePlayer != null && mc.theWorld != null) { + if (bedBreaker1.prioritizeKillAura.isEnabled() && OnyxClient.moduleManager.killAura.isEnabled()) { + if (OnyxClient.moduleManager.killAura.getPreviousTarget() != null) { + bedBreaker1.timer2.reset(); + } + + if (!bedBreaker1.timer2.hasReached(400L)) { + bedBreaker1.h(); + return; + } + } + + BlockPos blockPos1; + if ((blockPos1 = bedBreaker1.L()) == null) { + bedBreaker1.h(); + } else { + BlockPos blockPosx; + if ((blockPosx = bedBreaker1.L(blockPos1)) == null) { + bedBreaker1.h(); + } else { + bedBreaker1.blockPos = blockPos1; + Rotation rotation = RotationMath.L(bedBreaker1.L(blockPosx), RotationManager.L()); + bedBreaker1.L(blockPosx, rotation); + EnumFacing enumFacing = bedBreaker1.L(blockPosx, rotation); + bedBreaker1.L(blockPosx); + mc.playerController.onPlayerDamageBlock(blockPosx, enumFacing); + bedBreaker1.swing.getValue().L(); + bedBreaker1.blockPos2 = blockPosx; + bedBreaker1.blockPos3 = blockPosx; + } + } + } + } + + private void L(BlockPos blockPos) { + BedBreaker bedBreaker1 = this; + Block block = mc.theWorld.getBlockState(blockPosx).getBlock(); + int i = mc.thePlayer.inventory.currentItem; + int jx = mc.thePlayer.inventory.currentItem; + float fx = bedBreaker1.L(mc.thePlayer.inventory.getStackInSlot(i), block); + + for (int l = k = 0; l < 9; l = ++k) { + float g; + if ((g = bedBreaker1.L(mc.thePlayer.inventory.getStackInSlot(k), block)) > fx) { + fx = g; + jx = k; + } + } + + if (jx != i) { + if (bedBreaker1.j == -1) { + bedBreaker1.j = i; + } + + mc.thePlayer.inventory.currentItem = jx; + } + } + + private double L(BlockPos blockPos, Block block) { + float fx; + if ((fx = block.getBlockHardness(mc.theWorld, blockPosx)) < 0.0F) { + return -1.0; + } else { + return fx == 0.0F ? Double.MAX_VALUE : this.L(block) / fx; + } + } + + private void L(BlockPos blockPos, Rotation rotation) { + if (this.keepRotation.isEnabled()) { + RotationManager.setRotation(rotation, this.moveFix.getValue()); + } else if (!blockPosx.equals(this.blockPos2)) { + RotationManager.setRotation(rotation, this.moveFix.getValue()); + this.timer.reset(); + this.a = true; + } else { + if (this.a && this.timer.hasReached(10L)) { + RotationManager.d(); + this.a = false; + } + } + } + + public BedBreaker() { + super("BedBreaker", "Breaks nearby beds with the best tool", ModuleCategory.COMBAT); + this.keepRotation = new BooleanSetting("Keep rotation", false).describe("Holds the aim on the block the whole time instead of a brief flick per block"); + this.ignoreOwnBed = new BooleanSetting("Ignore own bed", true).describe("Skips your team's bed, found from the BedWars start message and base teleport"); + this.prioritizeKillAura = new BooleanSetting("Prioritize KillAura", false) + .describe("Pauses bed breaking while KillAura has a target so attacks take priority"); + this.j = -1; + this.timer = new Timer(); + this.timer2 = new Timer(); + } + + @Override + protected void onDisable() { + this.h(); + } + + private BlockPos[] L(BlockPos blockPos) { + IBlockState iBlockState; + if (!((iBlockState = mc.theWorld.getBlockState(blockPosx)).getBlock() instanceof BlockBed)) { + BlockPos[] blockPos2x = new BlockPos[1]; + boolean bl = true; + blockPos2x[0] = blockPosx; + return blockPos2x; + } else { + EnumPartType enumPartType = iBlockState.getValue(BlockBed.PART); + EnumFacing enumFacing = iBlockState.getValue(BlockBed.FACING); + BlockPos blockPos1 = blockPosx.offset(enumPartType == EnumPartType.HEAD ? enumFacing.getOpposite() : enumFacing); + BlockPos[] blockPos3x = new BlockPos[2]; + boolean bl1 = true; + blockPos3x[0] = blockPosx; + blockPos3x[1] = blockPos1; + return blockPos3x; + } + } + + public BlockPos getBlockPos3() { + return this.blockPos3; + } + + private float L(Block block) { + BedBreaker bedBreaker1 = this; + float fx = 1.0F; + + int i; + for (int jx = i = 0; jx < 9; jx = i) { + ItemStack itemStack = mc.thePlayer.inventory.getStackInSlot(i); + i++; + fx = Math.max(fx, bedBreaker1.L(itemStack, block)); + } + + return fx; + } + + private void h() { + if (this.blockPos3 != null) { + mc.playerController.resetBlockRemoving(); + this.blockPos3 = null; + } + + if (this.j != -1) { + if (mc.thePlayer != null) { + mc.thePlayer.inventory.currentItem = this.j; + if (mc.playerController != null) { + mc.playerController.syncCurrentPlayItem(); + } + } + + this.j = -1; + } + + this.blockPos2 = null; + this.blockPos = null; + this.a = false; + RotationManager.d(); + } + + private EnumFacing L(BlockPos blockPos) { + Vec3 vec3 = GeometryUtils.L(); + EnumFacing enumFacing = EnumFacing.UP; + double dx = Double.MAX_VALUE; + EnumFacing[] enumFacings; + int i = (enumFacings = EnumFacing.values()).length; + + int jx; + for (int k = jx = 0; k < i; k = ++jx) { + EnumFacing enumFacing1 = enumFacings[jx]; + if (BlockUtils.d(blockPosx.offset(enumFacing1))) { + Vec3 vec31 = new Vec3( + blockPosx.getX() + 0.5 + enumFacing1.getFrontOffsetX() * 0.5, + blockPosx.getY() + 0.5 + enumFacing1.getFrontOffsetY() * 0.5, + blockPosx.getZ() + 0.5 + enumFacing1.getFrontOffsetZ() * 0.5 + ); + double e; + if ((e = vec3.squareDistanceTo(vec31)) < dx) { + dx = e; + enumFacing = enumFacing1; + } + } + } + + return enumFacing; + } + + private boolean L(BlockPos blockPos) { + double dx = this.range.getFloat(); + Vec3 vec3 = GeometryUtils.L(); + return vec3.squareDistanceTo(GeometryUtils.L(vec3, this.L(blockPosx))) <= dx * dx; + } + + @EventHandler + public void onWorldChange(WorldChangeEvent worldChangeEvent) { + this.h(); + } + + private AxisAlignedBB L(BlockPos blockPos) { + return BlockUtils.L(blockPosx).offset(blockPosx.getX(), blockPosx.getY(), blockPosx.getZ()); + } + + public BlockPos getBlockPos() { + return this.blockPos; + } + + private boolean L(BlockPos blockPos, Block block) { + return BlockUtils.d(blockPosx) || block.getMaterial().isReplaceable(); + } + + private BlockPos L() { + BedBreaker bedBreaker1 = this; + double dx; + double g = dx = bedBreaker1.range.getFloat(); + double e = g * g; + Vec3 vec3 = GeometryUtils.L(); + if (bedBreaker1.blockPos != null + && mc.theWorld.getBlockState(bedBreaker1.blockPos).getBlock() instanceof BlockBed + && (!bedBreaker1.ignoreOwnBed.isEnabled() || !BedTracker.INSTANCE.L(bedBreaker1.blockPos)) + && vec3.squareDistanceTo(GeometryUtils.L(vec3, bedBreaker1.L(bedBreaker1.blockPos))) <= e) { + return bedBreaker1.blockPos; + } + + BlockPos blockPosx = new BlockPos(mc.thePlayer); + int l = (int)Math.ceil(dx); + BlockPos blockPos1 = null; + dx = Double.MAX_VALUE; + + int i; + int jx; + for (int o = i = -l; o <= l; o = ++i) { + int k; + for (int m = jx = -l; m <= l; m = ++jx) { + for (int n = k = -l; n <= l; n = ++k) { + BlockPos blockPos2x = blockPosx.add(i, jx, k); + double fx; + if (mc.theWorld.getBlockState(blockPos2x).getBlock() instanceof BlockBed + && (!bedBreaker1.ignoreOwnBed.isEnabled() || !BedTracker.INSTANCE.L(blockPos2x)) + && !((fx = vec3.squareDistanceTo(GeometryUtils.L(vec3, bedBreaker1.L(blockPos2x)))) > e) + && fx < dx) { + dx = fx; + blockPos1 = blockPos2x; + } + } + } + } + + return blockPos1; + } + + private Vec3 L(BlockPos blockPos) { + return GeometryUtils.L(GeometryUtils.L(), this.L(blockPosx)); + } +} diff --git a/src/openonyx/features/combat/BedDefender.java b/src/openonyx/features/combat/BedDefender.java new file mode 100644 index 0000000..86c4768 --- /dev/null +++ b/src/openonyx/features/combat/BedDefender.java @@ -0,0 +1,1214 @@ +package openonyx.features.combat; + +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonParser; +import java.util.ArrayList; +import java.util.Comparator; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Iterator; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.Map.Entry; +import java.util.concurrent.ThreadLocalRandom; +import meteordevelopment.orbit.EventHandler; +import net.minecraft.block.Block; +import net.minecraft.block.BlockBed; +import net.minecraft.block.BlockBed.EnumPartType; +import net.minecraft.block.state.IBlockState; +import net.minecraft.client.settings.KeyBinding; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.util.AxisAlignedBB; +import net.minecraft.util.BlockPos; +import net.minecraft.util.EnumFacing; +import net.minecraft.util.MovingObjectPosition; +import net.minecraft.util.Vec3; +import net.minecraft.util.MovingObjectPosition.MovingObjectType; +import openonyx.commands.Command; +import openonyx.configuration.internal.TickEvent; +import openonyx.core.OnyxClient; +import openonyx.events.GeometryUtils; +import openonyx.events.Rotation; +import openonyx.events.RotationFixMode; +import openonyx.events.RotationManager; +import openonyx.features.Module; +import openonyx.features.ModuleCategory; +import openonyx.history.internal.BooleanSetting; +import openonyx.history.internal.EnumSetting; +import openonyx.history.internal.NumberSetting; +import openonyx.interaction.BlockUtils; +import openonyx.interaction.SwingMode; +import openonyx.render.BoxRenderer; +import openonyx.utilities.BlockItemUtils; +import openonyx.utilities.RayTraceMode; +import openonyx.utilities.RayTraceUtils; +import org.apache.logging.log4j.Logger; + +public class BedDefender extends Module { + private static final double n = 4.5; + private BlockPos blockPos; + private BlockPos blockPos2; + public NumberSetting aimSpeed; + public EnumSetting moveFix; + private int V; + public BooleanSetting debugLogs; + public NumberSetting retryCooldown; + public NumberSetting sneakHoldTicks; + public NumberSetting targetLock; + private List defenseSteps; + private String F; + private int G; + public NumberSetting delayAfterAiming; + private boolean K; + private boolean B; + private final Set strings; + private static final String J = "{\"EndWoolCorners\":[{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":2}],\"EndWoolCorners2\":[{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":3}],\"EndGlassNoCorners\":[{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"stained_glass\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"stained_glass\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"stained_glass\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"stained_glass\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"stained_glass\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"stained_glass\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"stained_glass\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"stained_glass\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"stained_glass\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"stained_glass\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"stained_glass\",\"x\":0,\"y\":1,\"z\":2}],\"WoodWoolCorners\":[{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":1}],\"EndGlassWool\":[{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"stained_glass\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"stained_glass\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"stained_glass\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"stained_glass\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"stained_glass\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"stained_glass\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"stained_glass\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"stained_glass\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"stained_glass\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"stained_glass\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"stained_glass\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"stained_glass\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":-3,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":-3,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":-2,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-2,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":3},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":4},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":2,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":2,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":3,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":3,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":2},{\"block\":\"wool\",\"x\":-1,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":-2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-3},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":-2},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":-2},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":3,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":3,\"z\":1}],\"Wool1Layer\":[{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-1}],\"EndWoodLongCorners\":[{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"planks\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"planks\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"planks\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"planks\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"planks\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"planks\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"planks\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"planks\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"planks\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"planks\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"planks\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"planks\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":2}],\"EndWoolLong\":[{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":-2},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":-2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-3},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":-2}]}"; + private int D; + public EnumSetting order; + public NumberSetting stuckTimeout; + public NumberSetting targetsPerTick; + public NumberSetting delayAfterSwap; + public NumberSetting fov; + public BooleanSetting bedwarsOnly; + private final Map integerMap; + private static final Map> LIST_MAP = new LinkedHashMap<>(); + public BooleanSetting onlyTopBeds = new BooleanSetting("Only Top Beds", true).describe("Never click the side of a bed, only its top face"); + private boolean l; + private int I; + private static final float[] d; + private int i; + private BlockPos blockPos3; + public EnumSetting defense; + private final Map integerMap2; + + private int L(String string) { + BedDefender bedDefender1 = this; + String string2 = string.toLowerCase(); + String string1; + Integer integer; + if ((integer = bedDefender1.integerMap2.get(string2)) != null + && (string1 = L(mc.thePlayer.inventory.getStackInSlot(integer))) != null + && string1.equalsIgnoreCase(string)) { + return integer; + } + + bedDefender1.L(new StringBuilder().insert(0, "looking for block '").append(string2).append("' in hotbar").toString()); + + for (int j = ix = 0; j < 9; j = ++ix) { + ItemStack itemStack; + if ((itemStack = mc.thePlayer.inventory.getStackInSlot(ix)) != null) { + String string3 = L(itemStack); + bedDefender1.L("slot " + ix + " -> " + string3); + if (string3 != null && string3.equalsIgnoreCase(string)) { + bedDefender1.integerMap2.put(string2, ix); + return ix; + } + } + } + + return -1; + } + + private BlockPos L(int i) { + BlockPos blockPos4 = new BlockPos(mc.thePlayer); + int o = blockPos4.getX(); + int nx = blockPos4.getY(); + int j = blockPos4.getZ(); + double dx = Double.MAX_VALUE; + BlockPos blockPos1 = null; + + int k; + int lx; + for (int p = k = o - ix; p <= o + ix; p = ++k) { + int m; + for (int q = lx = nx - ix; q <= nx + ix; q = ++lx) { + for (int r = m = j - ix; r <= j + ix; r = ++m) { + BlockPos blockPosx = new BlockPos(k, lx, m); + if ("bed".equalsIgnoreCase(d(blockPosx))) { + BlockPos blockPos3x = null; + BlockPos blockPos2x = null; + switch (L(blockPosx)) { + case 0: + while (false) { + } + + blockPos2x = blockPosx; + blockPos4 = blockPos3x = blockPosx.add(0, 0, 1); + break; + case 1: + blockPos2x = blockPosx; + blockPos4 = blockPos3x = blockPosx.add(-1, 0, 0); + break; + case 2: + blockPos2x = blockPosx; + blockPos4 = blockPos3x = blockPosx.add(0, 0, -1); + break; + case 3: + blockPos2x = blockPosx; + blockPos4 = blockPos3x = blockPosx.add(1, 0, 0); + break; + case 8: + blockPos3x = blockPosx; + blockPos2x = blockPosx.add(0, 0, -1); + blockPos4 = blockPos3x; + break; + case 9: + blockPos3x = blockPosx; + blockPos2x = blockPosx.add(1, 0, 0); + blockPos4 = blockPos3x; + break; + case 10: + blockPos3x = blockPosx; + blockPos2x = blockPosx.add(0, 0, 1); + blockPos4 = blockPos3x; + break; + case 11: + blockPos3x = blockPosx; + blockPos2x = blockPosx.add(-1, 0, 0); + case 4: + case 5: + case 6: + case 7: + default: + blockPos4 = blockPos3x; + } + + if (blockPos4 != null && blockPos2x != null) { + double e = blockPos3x.distanceSq(o, nx, j); + double f = blockPos2x.distanceSq(o, nx, j); + double g = Math.min(e, f); + blockPosx = e <= f ? blockPos3x : blockPos2x; + if (g < dx) { + dx = g; + blockPos1 = blockPosx; + } + } + } + } + } + } + + return blockPos1; + } + + private boolean L(List list) { + if (list != null && !list.isEmpty()) { + HashSet hashSet = new HashSet(); + Iterator iterator = list.iterator(); + + while (iterator.hasNext()) { + DefenseStep defenseStep; + if ((defenseStep = (DefenseStep)iterator.next()).block() != null) { + hashSet.add(defenseStep.block().toLowerCase()); + } + } + + for (int j = ix = 0; j < 9; j = ++ix) { + String string; + if ((string = L(mc.thePlayer.inventory.getStackInSlot(ix))) != null && hashSet.contains(string.toLowerCase())) { + return true; + } + } + + return false; + } else { + return false; + } + } + + private Comparator L() { + switch ((PlacementOrder)this.order.getValue()) { + case PATTERN: + while (false) { + } + + return Comparator.comparingInt(bedTarget -> bedTarget.pos().getY()) + .thenComparing(Comparator.comparingDouble(BedTarget::distance).reversed()) + .thenComparingInt(BedTarget::index); + case NEAREST: + return Comparator.comparingDouble(BedTarget::distance).reversed().thenComparingInt(BedTarget::index); + case FURTHEST: + return Comparator.comparingDouble(BedTarget::distance).thenComparingInt(BedTarget::index); + case BOTTOM_UP: + return Comparator.comparingInt(BedTarget::index); + default: + throw new MatchException(null, null); + } + } + + @Override + protected void onDisable() { + if (this.K) { + d(false); + this.K = false; + } + + this.blockPos3 = null; + RotationManager.d(); + this.L("disabled."); + } + + private static double L(double d, double e) { + return ThreadLocalRandom.current().nextDouble(dx, e); + } + + private void k() { + if (this.K) { + if (this.V > 0) { + this.V--; + } else { + d(false); + this.K = false; + this.L("released sneak."); + } + } + } + + private void F() { + BedDefender bedDefender1 = this; + int j = 0; + bedDefender1.strings.clear(); + + for (int ix = 0; j < 9; j = ++ix) { + String string; + if ((string = L(mc.thePlayer.inventory.getStackInSlot(ix))) != null) { + bedDefender1.strings.add(string.toLowerCase()); + } + } + } + + private void L(BlockPos blockPos) { + BedDefender bedDefender1 = this; + int ix; + if ((ix = bedDefender1.retryCooldown.getInt()) > 0) { + bedDefender1.integerMap.put(blockPosx, ix); + } + } + + private static String L(Block block) { + Block block1 = block; + if (block1 == null) { + return "air"; + } + + Object object; + return (object = Block.blockRegistry.getNameForObject(block1)) == null ? "" : L(object.toString()); + } + + private static String L(String string) { + String string1 = string; + int ix; + return (ix = string1.indexOf(58)) < 0 ? string1 : string1.substring(ix + 1); + } + + private static float L(float f) { + float g; + return (g = (f % 360.0F + 360.0F) % 360.0F) > 180.0F ? g - 360.0F : g; + } + + private static MovingObjectPosition L(double d, float f, float g) { + MovingObjectPosition movingObjectPosition; + if ((movingObjectPosition = RayTraceUtils.L(dx, RayTraceMode.OUTLINE, false, GeometryUtils.L(), GeometryUtils.L(f, g))) == null + || movingObjectPosition.typeOfHit != MovingObjectType.BLOCK) { + return null; + } else { + return movingObjectPosition.getBlockPos() != null && movingObjectPosition.sideHit != null ? movingObjectPosition : null; + } + } + + public void L(float f) { + BedDefender bedDefender1 = this; + if (bedDefender1.isEnabled() && bedDefender1.blockPos3 != null && mc.theWorld != null) { + AxisAlignedBB axisAlignedBB = BlockUtils.AXIS_ALIGNED_BB + .offset(bedDefender1.blockPos3.getX(), bedDefender1.blockPos3.getY(), bedDefender1.blockPos3.getZ()); + if (BoxRenderer.L(f, true)) { + BoxRenderer.L(axisAlignedBB, -16711936, 1.5F, 1073807104); + BoxRenderer.L(); + } + } + } + + private float[] L(float f, float g, float h, float i) { + BedDefender bedDefender1 = this; + float j = bedDefender1.aimSpeed.getFloat(); + h -= f; + ix -= g; + f += Math.max(-j, Math.min(j, h)); + g += Math.max(-j, Math.min(j, ix)); + float[] k = new float[2]; + boolean bl = true; + k[0] = f; + k[1] = g; + return k; + } + + private float[] L(float f, float g, BlockPos blockPos, String string, float h, float i) { + MovingObjectPosition movingObjectPosition; + if ((movingObjectPosition = L(4.5, f, g)) == null) { + return null; + } + + BlockPos blockPos1 = movingObjectPosition.getBlockPos(); + EnumFacing enumFacing = movingObjectPosition.sideHit; + if (!blockPos1.offset(enumFacing).equals(blockPosx)) { + return null; + } + + String string1 = d(blockPos1); + if (this.onlyTopBeds.isEnabled() && enumFacing != EnumFacing.UP && string1.equals("bed")) { + return null; + } + + int j = mc.thePlayer.inventory.currentItem; + int k; + if ((k = this.L(string)) == -1) { + return null; + } + + if (j != k) { + this.L("switching to slot " + k + " for " + string); + mc.thePlayer.inventory.currentItem = k; + this.D = this.delayAfterSwap.getInt(); + } + + if (!this.L(blockPos1, enumFacing)) { + return null; + } + + if (this.D-- > 0) { + this.L(new StringBuilder().insert(0, "swap delay... (").append(this.D + 1).append(" left)").toString()); + return d; + } + + if (!mc.gameSettings.keyBindSneak.isKeyDown() && string1.equals("bed")) { + d(true); + this.K = true; + this.V = this.sneakHoldTicks.getInt(); + this.L("sneaking over bed for placement"); + return d; + } + + boolean bl = false; + MovingObjectPosition movingObjectPosition1; + if ((movingObjectPosition1 = L(4.5, h, ix)) != null) { + BlockPos blockPos2x = movingObjectPosition1.getBlockPos(); + EnumFacing enumFacing1 = movingObjectPosition1.sideHit; + if (blockPos2x.offset(enumFacing1).equals(blockPosx)) { + String string2 = d(blockPos2x); + if (!this.onlyTopBeds.isEnabled() || enumFacing1 == EnumFacing.UP || !string2.equals("bed")) { + bl = true; + } + } + } + + if (this.i <= 0 && bl) { + this.i = this.delayAfterAiming.getInt(); + boolean[] bl2 = new boolean[1]; + boolean bl3 = true; + bl2[0] = false; + boolean[] bl1 = bl2; + BlockUtils.L(movingObjectPosition1, () -> bl1[0] = true, () -> false, SwingMode.DO_NOT_HIDE); + if (bl1[0]) { + this.L(new StringBuilder().insert(0, "placed ").append(string).append(" at ").append(L(blockPosx)).toString()); + this.L(blockPosx); + this.blockPos2 = null; + } else { + this.L(new StringBuilder().insert(0, "place failed at ").append(L(blockPosx)).toString()); + } + + float[] lx = new float[2]; + bl3 = true; + lx[0] = h; + lx[1] = ix; + return lx; + } else { + if (this.i > 0) { + this.i--; + } + + return d; + } + } + + static { + JsonObject jsonObject2; + label87: { + JsonObject jsonObject; + try { + jsonObject = new JsonParser() + .parse( + "{\"EndWoolCorners\":[{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":2}],\"EndWoolCorners2\":[{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":3}],\"EndGlassNoCorners\":[{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"stained_glass\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"stained_glass\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"stained_glass\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"stained_glass\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"stained_glass\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"stained_glass\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"stained_glass\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"stained_glass\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"stained_glass\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"stained_glass\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"stained_glass\",\"x\":0,\"y\":1,\"z\":2}],\"WoodWoolCorners\":[{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":1}],\"EndGlassWool\":[{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"stained_glass\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"stained_glass\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"stained_glass\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"stained_glass\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"stained_glass\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"stained_glass\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"stained_glass\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"stained_glass\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"stained_glass\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"stained_glass\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"stained_glass\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"stained_glass\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"stained_glass\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":-3,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":-3,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":-2,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-2,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":3},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":4},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":2,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":2,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":3,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":3,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":2},{\"block\":\"wool\",\"x\":-1,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":-2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-3},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":-2},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":-2},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":3,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":3,\"z\":1}],\"Wool1Layer\":[{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-1}],\"EndWoodLongCorners\":[{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"planks\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"planks\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"planks\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"planks\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"planks\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"planks\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"planks\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"planks\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"planks\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"planks\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"planks\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"planks\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"planks\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"planks\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"planks\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"planks\",\"x\":-1,\"y\":0,\"z\":2}],\"EndWoolLong\":[{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":2},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":-1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-2},{\"block\":\"end_stone\",\"x\":0,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":-1},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":0},{\"block\":\"end_stone\",\"x\":1,\"y\":0,\"z\":1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":-1},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":0},{\"block\":\"end_stone\",\"x\":0,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":-2,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":-1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":-1},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":0},{\"block\":\"wool\",\"x\":0,\"y\":2,\"z\":1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":-1},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":0},{\"block\":\"wool\",\"x\":1,\"y\":1,\"z\":1},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":-1},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":0},{\"block\":\"wool\",\"x\":2,\"y\":0,\"z\":1},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":3},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":2},{\"block\":\"wool\",\"x\":1,\"y\":0,\"z\":-2},{\"block\":\"wool\",\"x\":0,\"y\":1,\"z\":-2},{\"block\":\"wool\",\"x\":0,\"y\":0,\"z\":-3},{\"block\":\"wool\",\"x\":-1,\"y\":0,\"z\":-2}]}" + ) + .getAsJsonObject(); + } catch (Exception exception2) { + jsonObject2 = new JsonObject(); + break label87; + } + + jsonObject2 = jsonObject; + } + + Iterator iterator; + for (Iterator iterator2 = iterator = jsonObject2.entrySet().iterator(); iterator2.hasNext(); iterator2 = iterator) { + Entry entry = (Entry)iterator.next(); + ArrayList arrayList = new ArrayList(); + + try { + Iterator iterator1 = ((JsonElement)entry.getValue()).getAsJsonArray().iterator(); + + label77: + while (true) { + Iterator iterator3 = iterator1; + + while (true) { + if (!iterator3.hasNext()) { + break label77; + } + + JsonElement jsonElement = (JsonElement)iterator1.next(); + + try { + JsonObject jsonObject1; + String string = (jsonObject1 = jsonElement.getAsJsonObject()).has("block") ? jsonObject1.get("block").getAsString() : ""; + if (!string.isEmpty()) { + DefenseStep defenseStep = new DefenseStep; + BlockPos blockPosx = new BlockPos; + int m; + JsonObject jsonObject3; + if (jsonObject1.has("x")) { + m = jsonObject1.get("x").getAsInt(); + jsonObject3 = jsonObject1; + } else { + m = 0; + jsonObject3 = jsonObject1; + } + + int lx; + JsonObject jsonObject4; + if (jsonObject3.has("y")) { + lx = jsonObject1.get("y").getAsInt(); + jsonObject4 = jsonObject1; + } else { + lx = 0; + jsonObject4 = jsonObject1; + } + + blockPosx./* $VF: Unable to resugar constructor */(m, lx, jsonObject4.has("z") ? jsonObject1.get("z").getAsInt() : 0); + defenseStep./* $VF: Unable to resugar constructor */(string, blockPosx); + arrayList.add(defenseStep); + break; + } + } catch (Exception exception) { + break; + } + + iterator3 = iterator1; + } + } + } catch (Exception exception1) { + } + + LIST_MAP.put((String)entry.getKey(), arrayList); + } + + DefensePattern[] defensePatterns; + int ix = (defensePatterns = DefensePattern.values()).length; + + int j; + for (int k = j = 0; k < ix; k = ++j) { + DefensePattern defensePattern = defensePatterns[j]; + if (!LIST_MAP.containsKey(defensePattern.getDisplayName())) { + Logger logger = OnyxClient.LOGGER; + Object[] objects = new Object[1]; + boolean bl1 = true; + objects[0] = defensePattern.getDisplayName(); + logger.warn("BedDefender: no defense named '{}' in the embedded JSON", objects); + } + } + + float[] f = new float[2]; + boolean bl = true; + f[0] = -999.0F; + f[1] = -999.0F; + d = f; + } + + private static float d(float f, float g) { + return g + (((f - g + 180.0F) % 360.0F + 360.0F) % 360.0F - 180.0F); + } + + private static String L(ItemStack itemStack) { + ItemStack itemStack1 = itemStack; + if (itemStack1 == null) { + return null; + } + + Block block; + if ((block = BlockItemUtils.L(itemStack1)) != null) { + return L(block); + } + + Object object; + return (object = Item.itemRegistry.getNameForObject(itemStack1.getItem())) == null ? null : L(object.toString()); + } + + private static float[] L(Vec3 vec3, double d, double e, double g) { + dx -= vec3.xCoord; + e -= vec3.yCoord; + g -= vec3.zCoord; + double h = Math.sqrt(dx * dx + g * g); + float ix = L((float)Math.toDegrees(Math.atan2(g, dx)) - 90.0F); + float f = (float)Math.toDegrees(-Math.atan2(e, h)); + float[] j = new float[2]; + boolean bl = true; + j[0] = ix; + j[1] = f; + return j; + } + + private static boolean d(BlockPos blockPos) { + BlockPos blockPos1 = blockPosx; + EnumFacing[] enumFacings; + int ix = (enumFacings = EnumFacing.values()).length; + + for (int k = j = 0; k < ix; k = ++j) { + EnumFacing enumFacing = enumFacings[j]; + if (!"air".equals(d(blockPos1.offset(enumFacing)))) { + return true; + } + } + + return false; + } + + private static String d(BlockPos blockPos) { + return L(BlockUtils.L(blockPosx)); + } + + private float[] d() { + BedDefender bedDefender1 = this; + float j; + float g = j = bedDefender1.fov.getFloat(); + j = Math.min(j, 90.0F); + Rotation rotation = RotationManager.L(); + float h = rotation.yaw(); + float f = rotation.pitch(); + if (!bedDefender1.B) { + BlockPos blockPos1; + if (bedDefender1.bedwarsOnly.isEnabled()) { + if ((blockPos1 = BedTracker.INSTANCE.L()) == null) { + bedDefender1.L("no whitelisted bed. disabling."); + return bedDefender1.L(); + } + + if (!"bed".equalsIgnoreCase(d(blockPos1))) { + bedDefender1.L("whitelisted bed pos is stale/not a bed. disabling."); + return bedDefender1.L(); + } + } else { + if ((blockPos1 = bedDefender1.L(16)) == null) { + bedDefender1.L("no bed in range. disabling."); + return bedDefender1.L(); + } + + if (!"bed".equalsIgnoreCase(d(blockPos1))) { + bedDefender1.L("findBed returned invalid target. disabling."); + return bedDefender1.L(); + } + } + + bedDefender1.L( + new StringBuilder() + .insert(0, "bed found at ") + .append(blockPos1.getX()) + .append(",") + .append(blockPos1.getY()) + .append(",") + .append(blockPos1.getZ()) + .toString() + ); + bedDefender1.blockPos = blockPos1; + BedDefender bedDefender2; + switch (L(blockPos1)) { + case 0: + case 10: + bedDefender2 = bedDefender1; + + while (false) { + } + + bedDefender1.F = "north"; + break; + case 1: + case 11: + bedDefender2 = bedDefender1; + bedDefender1.F = "east"; + break; + case 2: + case 8: + bedDefender2 = bedDefender1; + bedDefender1.F = "south"; + break; + case 3: + case 9: + bedDefender2 = bedDefender1; + bedDefender1.F = "west"; + break; + case 4: + case 5: + case 6: + case 7: + default: + bedDefender2 = bedDefender1; + bedDefender1.F = ""; + } + + bedDefender2.L(new StringBuilder().insert(0, "lockedDirection=").append(bedDefender1.F).toString()); + bedDefender1.B = true; + } + + bedDefender1.h(); + bedDefender1.F(); + int lx = 0; + boolean bl = false; + ArrayList arrayList = new ArrayList(); + ArrayList arrayList1 = new ArrayList(); + Vec3 vec3 = GeometryUtils.L(); + + int ix; + for (int nx = ix = 0; nx < bedDefender1.defenseSteps.size(); nx = ++ix) { + DefenseStep defenseStep = bedDefender1.defenseSteps.get(ix); + BlockPos blockPosx = bedDefender1.blockPos.add(L(defenseStep.offset(), bedDefender1.F)); + if ("air".equals(d(blockPosx))) { + lx++; + arrayList1.add(blockPosx); + boolean bl1 = bedDefender1.strings.contains(defenseStep.block().toLowerCase()); + bl |= bl1; + if (bl1 && d(blockPosx) && L(blockPosx)) { + double dx = blockPosx.getX() + 0.5 - vec3.xCoord; + double e = blockPosx.getY() + 0.5 - vec3.yCoord; + double k = blockPosx.getZ() + 0.5 - vec3.zCoord; + if (!((dx = dx * dx + e * e + k * k) > 36.0)) { + arrayList.add(new BedTarget(blockPosx, defenseStep.block(), ix, dx)); + } + } + } + } + + if (lx == 0) { + bedDefender1.L("done (pattern filled)."); + return bedDefender1.L(); + } + + if (!bl) { + bedDefender1.L("no block left in the hotbar for anything still open (disabling)"); + return bedDefender1.L(); + } + + HashMap hashMap = new HashMap(); + Iterator iterator; + Iterator iterator1 = iterator = arrayList.iterator(); + + while (iterator1.hasNext()) { + BedTarget bedTarget = (BedTarget)iterator.next(); + iterator1 = iterator; + hashMap.put(bedTarget.pos(), L(bedTarget, arrayList1, vec3)); + } + + arrayList.sort(Comparator.comparingInt(bedTarget -> (Integer)hashMap.get(bedTargetx.pos())).thenComparing(bedDefender1.L())); + float[] m; + if ((m = bedDefender1.L(arrayList, h, f, g, j)) != null) { + return m; + } else { + bedDefender1.I++; + if (bedDefender1.stuckTimeout.getInt() > 0 && bedDefender1.I > bedDefender1.stuckTimeout.getInt()) { + bedDefender1.L("nothing placeable for " + bedDefender1.I + " ticks (disabling)"); + return bedDefender1.L(); + } else { + bedDefender1.blockPos3 = arrayList.isEmpty() ? null : ((BedTarget)arrayList.get(0)).pos(); + return null; + } + } + } + + public boolean I() { + return this.isEnabled(); + } + + private void l() { + this.l = false; + RotationManager.d(); + this.setEnabled(false); + } + + private float[] L() { + this.l = true; + return null; + } + + private float[] L(BedTarget bedTarget, float f, float g, float h, float i) { + BedDefender bedDefender1 = this; + BlockPos blockPos1 = bedTarget.pos(); + String string = bedTarget.block(); + float j = f; + float k = g; + float[] lx; + if ((lx = bedDefender1.L(j, k, blockPos1, string, f, g)) != null) { + return lx[1] == -999.0F ? bedDefender1.L(f, g, j, k) : lx; + } + + EnumFacing[] enumFacings1 = new EnumFacing[6]; + boolean bl2 = true; + enumFacings1[0] = EnumFacing.DOWN; + enumFacings1[1] = EnumFacing.UP; + enumFacings1[2] = EnumFacing.SOUTH; + enumFacings1[3] = EnumFacing.NORTH; + enumFacings1[4] = EnumFacing.WEST; + enumFacings1[5] = EnumFacing.EAST; + EnumFacing[] enumFacings = enumFacings1; + int[] bk = new int[6]; + bl2 = true; + bk[0] = 0; + bk[1] = 0; + bk[2] = 0; + bk[3] = 0; + bk[4] = 1; + bk[5] = -1; + int[] bd = bk; + int[] be = new int[]{1, -1, 0, 0, 0, 0}; + int[] bm = new int[6]; + bl2 = true; + bm[0] = 0; + bm[1] = 0; + bm[2] = -1; + bm[3] = 1; + bm[4] = 0; + bm[5] = 0; + int[] m = bm; + Vec3 vec3 = GeometryUtils.L(); + float nx = L(f); + float o = g; + float p = L(mc.thePlayer.rotationYaw); + float q = mc.thePlayer.rotationPitch; + double dx = 0.05; + double e = 0.2; + double r = 0.2; + double s = 1.0 - dx - 0.001; + dx += 0.001; + int t = (int)Math.round(1.0 / e); + ArrayList arrayList = new ArrayList((t + 1) * (t + 1) * 6); + + for (int bn = bc = 0; bn < 6; bn = ++bc) { + EnumFacing enumFacing = enumFacings[bc]; + BlockPos blockPosx; + String string1; + int u; + if (!(string1 = d(blockPosx = blockPos1.add(bd[bc], be[bc], m[bc]))).equals("air") + && (!bedDefender1.onlyTopBeds.isEnabled() || !string1.equals("bed") || enumFacing == EnumFacing.UP)) { + for (int bo = u = 0; bo <= t; bo = ++u) { + boolean bl = (u & 1) == 0; + double v; + if ((v = u * e + L(-e * r, e * r)) < 0.0) { + v = 0.0; + } else if (v > 1.0) { + v = 1.0; + } + + int w; + for (int bp = w = 0; bp <= t; bp = ++w) { + double x; + boolean bl1; + if ((x = w * e + L(-e * r, e * r)) < 0.0) { + x = 0.0; + bl1 = bl; + } else { + if (x > 1.0) { + x = 1.0; + } + + bl1 = bl; + } + + double y = bl1 ? x : 1.0 - x; + double z; + double ba; + Vec3 vec31; + if (bc < 2) { + x = blockPosx.getX() + y; + ba = blockPosx.getZ() + v; + z = blockPosx.getY() + (bc == 1 ? s : dx); + vec31 = vec3; + } else if (bc < 4) { + x = blockPosx.getX() + y; + z = blockPosx.getY() + v; + ba = blockPosx.getZ() + (bc == 2 ? s : dx); + vec31 = vec3; + } else { + ba = blockPosx.getZ() + y; + z = blockPosx.getY() + v; + x = blockPosx.getX() + (bc == 5 ? s : dx); + vec31 = vec3; + } + + float[] bq = L(vec31, x, z, ba); + float bb = bq[0]; + float bj = bq[1]; + if (!(Math.abs(L(p, bb)) > h) && !(Math.abs(bj - q) > ix) && !(Math.abs(bj) > 90.0F)) { + x = Math.abs((double)L(nx, bb)) + Math.abs((double)(bj - o)) + (enumFacing == EnumFacing.UP ? -0.25 : 0.0); + Object[] objects1 = new Object[3]; + boolean bl3 = true; + objects1[0] = x; + objects1[1] = bb; + objects1[2] = bj; + arrayList.add(objects1); + } + } + } + } + } + + if (arrayList.isEmpty()) { + bedDefender1.L("no aim candidates (FOV/angles?)"); + return null; + } + + arrayList.sort(Comparator.comparingDouble(objects -> (Double)objectsx[0])); + Iterator iterator = arrayList.iterator(); + + while (iterator.hasNext()) { + Object[] objects; + float bf = (Float)(objects = (Object[])iterator.next())[1]; + float bg = (Float)objects[2]; + float bh = d(bf, f); + float[] bi; + if ((bi = bedDefender1.L(bh, bg, blockPos1, string, f, g)) != null) { + if (bi[1] == -999.0F) { + return bedDefender1.L(f, g, bh, bg); + } + + return bi; + } + } + + return null; + } + + private static boolean L(BlockPos blockPos) { + return mc.theWorld.checkNoEntityCollision(BlockUtils.AXIS_ALIGNED_BB.offset(blockPosx.getX(), blockPosx.getY(), blockPosx.getZ())); + } + + private static float L(float f, float g) { + float h; + float ix = h = g - f; + + while (ix <= -180.0F) { + ix = h += 360.0F; + } + + ix = h; + + while (ix > 180.0F) { + ix = h -= 360.0F; + } + + return h; + } + + private static int L(BedTarget bedTarget, List list, Vec3 vec3) { + BedTarget bedTarget1 = bedTarget; + AxisAlignedBB axisAlignedBB = new AxisAlignedBB( + bedTarget1.pos().getX(), + bedTarget1.pos().getY(), + bedTarget1.pos().getZ(), + bedTarget1.pos().getX() + 1, + bedTarget1.pos().getY() + 1, + bedTarget1.pos().getZ() + 1 + ); + int ix = 0; + Iterator iterator = list.iterator(); + + label24: + while (true) { + Iterator iterator1 = iterator; + + while (iterator1.hasNext()) { + BlockPos blockPosx; + if ((blockPosx = (BlockPos)iterator.next()).equals(bedTarget1.pos())) { + iterator1 = iterator; + } else { + Vec3 vec31 = new Vec3(blockPosx.getX() + 0.5, blockPosx.getY() + 0.5, blockPosx.getZ() + 0.5); + if (!(vec3.squareDistanceTo(vec31) <= bedTarget1.distance())) { + if (axisAlignedBB.calculateIntercept(vec3, vec31) != null) { + ix++; + } + continue label24; + } + + iterator1 = iterator; + } + } + + return ix; + } + } + + private static String L(BlockPos blockPos) { + return blockPosx.getX() + "," + blockPosx.getY() + "," + blockPosx.getZ(); + } + + @Override + protected void onEnable() { + this.defenseSteps = LIST_MAP.getOrDefault(this.defense.getValue().getDisplayName(), new ArrayList<>()); + BedDefender bedDefender1; + if (this.defenseSteps.isEmpty()) { + this.L("enabled, but no defenses loaded."); + bedDefender1 = this; + } else { + this.L( + new StringBuilder() + .insert(0, "enabled. defense='") + .append(this.defense.getValue().getDisplayName()) + .append("' steps=") + .append(this.defenseSteps.size()) + .toString() + ); + if (!this.L(this.defenseSteps)) { + this.L("no required blocks for selected defense in hotbar (disabling)"); + this.l = true; + } + + bedDefender1 = this; + } + + bedDefender1.blockPos3 = null; + this.blockPos2 = null; + this.G = 0; + this.I = 0; + this.integerMap.clear(); + this.strings.clear(); + this.B = false; + this.K = false; + this.F = ""; + this.i = this.delayAfterAiming.getInt(); + this.integerMap2.clear(); + } + + private boolean L(BlockPos blockPos, EnumFacing enumFacing) { + return "air".equalsIgnoreCase(d(blockPosx.offset(enumFacing))); + } + + private static int L(BlockPos blockPos) { + BlockPos blockPos1 = blockPosx; + IBlockState iBlockState; + return (iBlockState = BlockUtils.L(blockPos1)) != null && iBlockState.getBlock() instanceof BlockBed + ? iBlockState.getValue(BlockBed.FACING).getHorizontalIndex() | (iBlockState.getValue(BlockBed.PART) == EnumPartType.HEAD ? 8 : 0) + : -1; + } + + @EventHandler + public void onTick(TickEvent tickEvent) { + if (mc.thePlayer != null && mc.theWorld != null) { + if (this.l) { + this.l(); + } else { + this.k(); + float[] f = this.d(); + if (this.l) { + this.l(); + } else if (f == null) { + RotationManager.d(); + } else { + RotationManager.setRotation(new Rotation(f[0], f[1]), this.moveFix.getValue()); + } + } + } + } + + private static BlockPos L(BlockPos blockPos, String string) { + BlockPos blockPos1; + int ix; + int j; + byte c; + label36: { + blockPos1 = blockPosx; + k = blockPos1.getX(); + j = blockPos1.getY(); + ix = blockPos1.getZ(); + String string1 = string; + byte b = -1; + switch (string1.hashCode()) { + case 3105789: + while (false) { + } + + if (string1.equals("east")) { + c = b = 2; + break label36; + } + break; + case 3645871: + if (string1.equals("west")) { + b = 3; + } + break; + case 105007365: + if (string1.equals("north")) { + c = b = 0; + break label36; + } + break; + case 109627853: + if (string1.equals("south")) { + c = b = 1; + break label36; + } + } + + c = b; + } + + switch (c) { + case 0: + return new BlockPos(k, j, ix); + case 1: + return new BlockPos(-k, j, -ix); + case 2: + return new BlockPos(-ix, j, k); + case 3: + return new BlockPos(ix, j, -k); + default: + return blockPos1; + } + } + + private float[] L(List list, float f, float g, float h, float i) { + BedDefender bedDefender1; + BedTarget bedTarget3; + label58: { + bedDefender1 = this; + bedTarget2 = null; + if (bedDefender1.blockPos2 != null) { + Iterator iterator = list.iterator(); + + while (iterator.hasNext()) { + BedTarget bedTarget; + if ((bedTarget = (BedTarget)iterator.next()).pos().equals(bedDefender1.blockPos2)) { + bedTarget3 = bedTarget2 = bedTarget; + break label58; + } + } + } + + bedTarget3 = bedTarget2; + } + + if (bedTarget3 != null && bedDefender1.G > 0) { + bedDefender1.G--; + float[] k; + if ((k = bedDefender1.L(bedTarget2, f, g, h, ix)) != null) { + bedDefender1.blockPos3 = bedTarget2.pos(); + bedDefender1.I = 0; + return k; + } + + bedDefender1.L(new StringBuilder().insert(0, "lost the aim on ").append(L(bedTarget2.pos())).append(", moving on").toString()); + bedDefender1.L(bedTarget2.pos()); + } + + bedDefender1.blockPos2 = null; + int lx = bedDefender1.targetsPerTick.getInt(); + int m = 0; + Iterator iterator1; + Iterator iterator2 = iterator1 = list.iterator(); + + while (true) { + if (!iterator2.hasNext()) { + nx = m; + break; + } + + BedTarget bedTarget1 = (BedTarget)iterator1.next(); + if (bedDefender1.integerMap.containsKey(bedTarget1.pos())) { + iterator2 = iterator1; + } else { + if (m >= lx) { + nx = m; + break; + } + + m++; + float[] j; + if ((j = bedDefender1.L(bedTarget1, f, g, h, ix)) != null) { + bedDefender1.blockPos2 = bedTarget1.pos(); + bedDefender1.G = bedDefender1.targetLock.getInt(); + bedDefender1.blockPos3 = bedTarget1.pos(); + bedDefender1.I = 0; + return j; + } + + bedDefender1.L(bedTarget1.pos()); + iterator2 = iterator1; + } + } + + if (nx == 0 && !list.isEmpty()) { + bedDefender1.integerMap.clear(); + } + + return null; + } + + private static void d(boolean bl) { + KeyBinding.setKeyBindState(mc.gameSettings.keyBindSneak.getKeyCode(), bl); + } + + private void L(String string) { + if (this.debugLogs.isEnabled()) { + Command.L(new StringBuilder().insert(0, "[beddef] ").append(string).toString()); + } + } + + private void h() { + this.integerMap.entrySet().removeIf(entry -> { + entry.setValue(entry.getValue() - 1); + return entry.getValue() <= 0; + }); + } + + public BedDefender() { + super("BedDefender", "Walls your bed in with a preset defense pattern", ModuleCategory.COMBAT); + this.bedwarsOnly = new BooleanSetting("Bedwars Only", true).describe("Anchor to the tracked team bed instead of the nearest bed in range"); + this.delayAfterSwap = new NumberSetting("Delay After Swap", 0.0, 0.0, 10.0, 1.0).withSuffix(" ticks"); + this.delayAfterAiming = new NumberSetting("Delay After Aiming", 0.0, 0.0, 10.0, 1.0).withSuffix(" ticks"); + this.sneakHoldTicks = new NumberSetting("Sneak Hold Ticks", 5.0, 0.0, 20.0, 1.0).withSuffix(" ticks"); + this.aimSpeed = new NumberSetting("Aim Speed", 20.0, 1.0, 180.0, 1.0).withSuffix(" deg/t"); + this.fov = new NumberSetting("FOV", 180.0, 0.0, 180.0, 1.0).describe("How far off your own aim a candidate placement angle may be"); + this.defense = new EnumSetting<>("Defense", DefensePattern.END_GLASS_NO_CORNERS); + this.order = new EnumSetting<>("Order", PlacementOrder.BOTTOM_UP) + .describe( + "Which open spot to wall in first when several are placeable - whatever this says, a spot standing in front of another is still left for last" + ); + this.targetsPerTick = new NumberSetting("Targets Per Tick", 4.0, 1.0, 16.0, 1.0) + .describe("How many different spots to search for an aim each tick before giving up on the tick"); + this.targetLock = new NumberSetting("Target Lock", 30.0, 5.0, 100.0, 5.0) + .withSuffix(" ticks") + .describe("How long to keep turning toward one spot before writing it off and trying another"); + this.retryCooldown = new NumberSetting("Retry Cooldown", 20.0, 0.0, 100.0, 5.0) + .withSuffix(" ticks") + .describe("How long a spot that could not be reached is skipped before it is tried again"); + this.stuckTimeout = new NumberSetting("Stuck Timeout", 100.0, 0.0, 400.0, 20.0) + .withSuffix(" ticks") + .describe("Turn off after this long with nothing placeable - 0 never gives up"); + this.moveFix = new EnumSetting<>("Move fix", RotationFixMode.SILENT).describe("Keeps movement consistent with the rotation the server sees"); + this.debugLogs = new BooleanSetting("Debug Logs", false); + this.F = ""; + this.integerMap2 = new HashMap<>(); + this.defenseSteps = new ArrayList<>(); + this.integerMap = new HashMap<>(); + this.strings = new HashSet<>(); + } +}