Вопрос Перенесите эти коды на epxensive 3.1

Забаненный
Статус
Оффлайн
Регистрация
5 Май 2024
Сообщения
44
Реакции[?]
0
Поинты[?]
0
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.

Перед прочтением основного контента ниже, пожалуйста, обратите внимание на обновление внутри секции Майна на нашем форуме. У нас появились:

  • бесплатные читы для Майнкрафт — любое использование на свой страх и риск;
  • маркетплейс Майнкрафт — абсолютно любая коммерция, связанная с игрой, за исключением продажи читов (аккаунты, предоставления услуг, поиск кодеров читов и так далее);
  • приватные читы для Minecraft — в этом разделе только платные хаки для игры, покупайте группу "Продавец" и выставляйте на продажу свой софт;
  • обсуждения и гайды — всё тот же раздел с вопросами, но теперь модернизированный: поиск нужных хаков, пати с игроками-читерами и другая полезная информация.

Спасибо!

//1
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package im.expensive.modules.impl.movement;

import net.minecraft.inventory.container.ClickType;
import net.minecraft.item.ItemStack;
import net.minecraft.item.Items;
import net.minecraft.network.play.client.CEntityActionPacket;
import net.minecraft.network.play.client.CEntityActionPacket.Action;
import net.minecraft.network.play.server.SEntityMetadataPacket;
import net.minecraft.util.Hand;
import net.minecraft.util.text.TextFormatting;
import im.expensive.events.Event;
import im.expensive.events.impl.packet.EventPacket;
import im.expensive.events.impl.player.EventMotion;
import im.expensive.events.impl.player.EventUpdate;
import im.expensive.modules.Function;
import im.expensive.modules.FunctionAnnotation;
import im.expensive.modules.Type;
import im.expensive.modules.settings.Setting;
import im.expensive.modules.settings.imp.BooleanOption;
import im.expensive.modules.settings.imp.SliderSetting;
import im.expensive.util.ClientUtil;
import im.expensive.util.misc.TimerUtil;
import im.expensive.util.movement.MoveUtil;
import im.expensive.util.world.InventoryUtil;

@FunctionAnnotation(
name = "CatStrafe",
type = Type.Movement
)
public class CatStrafe extends Function {
private final TimerUtil timerUtil = new TimerUtil();
int oldItem = -1;
private final SliderSetting speedBoost = new SliderSetting("Скорость", 0.3F, 0.0F, 0.8F, 1.0E-4F);
private final BooleanOption autoJump = new BooleanOption("Авто прыжок", false);
private final BooleanOption safeMode = new BooleanOption("Безопасный режим", false);
boolean test1 = false;

public CatStrafe() {
this.addSettings(new Setting[]{this.speedBoost, this.safeMode, this.autoJump});
}

protected void onEnable() {
super.onEnable();
}

public void onEvent(Event event) {
if (event instanceof EventUpdate) {
if (mc.player.collidedHorizontally && this.safeMode.get()) {
ClientUtil.sendMesage(TextFormatting.RED + "Вы столкнулись с блоком, перезапустите функцию!");
this.toggle();
return;
}

if (InventoryUtil.getItemSlot(Items.FIREWORK_ROCKET) == -1 || mc.player.collidedHorizontally || !InventoryUtil.doesHotbarHaveItem(Items.ELYTRA)) {
return;
}

if (this.autoJump.get() && !mc.gameSettings.keyBindJump.isKeyDown() && mc.player.isOnGround()) {
mc.gameSettings.keyBindJump.setPressed(true);
}

if (mc.player.getActiveHand() == Hand.MAIN_HAND) {
mc.playerController.onStoppedUsingItem(mc.player);
}
}

if (event instanceof EventMotion eventMotion) {
eventMotion.setPitch(15.0F);
mc.player.rotationPitchHead = 15.0F;
}

if (event instanceof EventUpdate) {
mc.gameSettings.keyBindBack.setPressed(false);
mc.gameSettings.keyBindLeft.setPressed(false);
mc.gameSettings.keyBindRight.setPressed(false);
boolean test = false;
if ((mc.player.isOnGround() || mc.player.fallDistance != 0.0F && mc.gameSettings.keyBindJump.isKeyDown()) && this.timerUtil.hasTimeElapsed(600L)) {
test = true;
}

if (mc.player.isOnGround() && test) {
mc.gameSettings.keyBindForward.setPressed(false);
return;
}

if (mc.player.fallDistance == 0.0F && !mc.player.isOnGround()) {
test = false;
}

for(int i = 0; i < 9; ++i) {
if (mc.player.inventory.getStackInSlot(i).getItem() == Items.ELYTRA && !mc.player.isOnGround() && !mc.player.isInWater() && !mc.player.isInLava()) {
float speed;
if (InventoryUtil.doesHotbarHaveItem(Items.FIREWORK_ROCKET) && this.timerUtil.hasTimeElapsed(300L)) {
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_FALL_FLYING));
speed = 0.9F + this.speedBoost.getValue().floatValue();
MoveUtil.setMotion((double)speed);
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
if (this.timerUtil.hasTimeElapsed(300L)) {
InventoryUtil.inventorySwapClick(Items.FIREWORK_ROCKET, false);
this.timerUtil.reset();
}
}

if (!InventoryUtil.doesHotbarHaveItem(Items.FIREWORK_ROCKET) && this.timerUtil.hasTimeElapsed(300L)) {
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_FALL_FLYING));
speed = 0.9F + this.speedBoost.getValue().floatValue();
MoveUtil.setMotion((double)speed);
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
if (this.timerUtil.hasTimeElapsed(300L)) {
InventoryUtil.inventorySwapClick(Items.FIREWORK_ROCKET, false);
this.timerUtil.reset();
}
}
}
}
}

if (event instanceof EventPacket e) {
if (e.getPacket() instanceof SEntityMetadataPacket && ((SEntityMetadataPacket)e.getPacket()).getEntityId() == mc.player.getEntityId()) {
e.setCancel(true);
}
}

}

public void onDisable() {
super.onDisable();
if (this.oldItem != -1) {
if (((ItemStack)mc.player.inventory.armorInventory.get(2)).getItem() == Items.ELYTRA) {
mc.playerController.windowClick(0, this.oldItem < 9 ? this.oldItem + 36 : this.oldItem, 38, ClickType.SWAP, mc.player);
}

this.oldItem = -1;
}

}
}
//2
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.movement;

import net.minecraft.block.Blocks;
import net.minecraft.inventory.container.ClickType;
import net.minecraft.item.Items;
import net.minecraft.item.UseAction;
import net.minecraft.network.play.client.CEntityActionPacket;
import net.minecraft.network.play.client.CEntityActionPacket.Action;
import net.minecraft.util.Hand;
import net.minecraft.util.math.BlockPos;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;
import wtf.expensive.modules.settings.Setting;
import wtf.expensive.modules.settings.imp.BooleanOption;
import wtf.expensive.modules.settings.imp.SliderSetting;
import wtf.expensive.util.misc.TimerUtil;
import wtf.expensive.util.world.InventoryUtil;

@FunctionAnnotation(
name = "CatFly",
type = Type.Movement
)
public class CatFly extends Function {
private final TimerUtil timerUtil = new TimerUtil();
private final TimerUtil timerUtil1 = new TimerUtil();
private final SliderSetting timerStartFireWork = new SliderSetting("Таймер фейерверка", 400.0F, 50.0F, 1500.0F, 1.0F);
private final BooleanOption onlyGrimBypass = new BooleanOption("Обходить только грим", false);
private final BooleanOption noFireWorkifEat = new BooleanOption("Отсутствие еды в правой руке", false);

public CatFly() {
this.addSettings(new Setting[]{this.timerStartFireWork, this.onlyGrimBypass, this.noFireWorkifEat});
}

public void onEvent(Event event) {
if (InventoryUtil.getItemSlot(Items.FIREWORK_ROCKET) != -1) {
if (event instanceof EventUpdate) {
int timeSwap = 200;
if (this.onlyGrimBypass.get()) {
timeSwap = 0;
}

boolean startFireWork = true;
if (this.noFireWorkifEat.get() && mc.player.getActiveHand() == Hand.MAIN_HAND && mc.player.getHeldItemMainhand().getUseAction() == UseAction.EAT) {
startFireWork = false;
}

for(int i = 0; i < 9; ++i) {
if (mc.player.inventory.getStackInSlot(i).getItem() == Items.ELYTRA && mc.world.getBlockState(new BlockPos(mc.player.getPosX(), mc.player.getPosY() - 0.01, mc.player.getPosZ())).getBlock() == Blocks.AIR && !mc.player.isOnGround() && !mc.player.isInWater() && !mc.player.isInLava() && !mc.player.isElytraFlying()) {
if (this.timerUtil1.hasTimeElapsed((long)timeSwap)) {
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
mc.player.startFallFlying();
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_FALL_FLYING));
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
this.timerUtil1.reset();
}

if (this.timerUtil.hasTimeElapsed((long)this.timerStartFireWork.getValue().intValue()) && mc.player.isElytraFlying()) {
if (startFireWork) {
InventoryUtil.inventorySwapClick(Items.FIREWORK_ROCKET, false);
}

this.timerUtil.reset();
}
}
}
}

}
}

public void onDisable() {
super.onDisable();
}
}

//3
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.movement;

import net.minecraft.item.UseAction;
import net.minecraft.network.IPacket;
import net.minecraft.network.play.client.CHeldItemChangePacket;
import net.minecraft.network.play.client.CPlayerTryUseItemPacket;
import net.minecraft.network.play.server.SEntityVelocityPacket;
import net.minecraft.network.play.server.SHeldItemChangePacket;
import net.minecraft.network.play.server.SPlayerPositionLookPacket;
import net.minecraft.util.Hand;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.packet.EventPacket;
import wtf.expensive.events.impl.player.EventDamage;
import wtf.expensive.events.impl.player.EventNoSlow;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;
import wtf.expensive.modules.settings.Setting;
import wtf.expensive.modules.settings.imp.BooleanOption;
import wtf.expensive.modules.settings.imp.ModeSetting;
import wtf.expensive.util.misc.DamageUtil;
import wtf.expensive.util.misc.TimerUtil;
import wtf.expensive.util.movement.MoveUtil;

@FunctionAnnotation(
name = "NoSlow",
type = Type.Movement
)
public class NoSlowFunction extends Function {
public ModeSetting mode = new ModeSetting("Мод", "Really World", new String[]{"Vanilla", "Really World", "GrimAC"});
private DamageUtil damageUtil = new DamageUtil();
public TimerUtil timerUtil = new TimerUtil();
public BooleanOption matrix = new BooleanOption("Фикс свапа", true);
public BooleanOption matrix1 = (new BooleanOption("Работать только в воде", true)).setVisible(() -> {
return this.mode.is("Really World");
});
public BooleanOption matrix2 = (new BooleanOption("Работать только от урона", true)).setVisible(() -> {
return this.mode.is("Really World");
});
public BooleanOption matrix3 = (new BooleanOption("Выключить работать от урона", true)).setVisible(() -> {
return this.mode.is("Really World");
});
boolean restart = false;
boolean restart1 = false;
boolean test = true;

public NoSlowFunction() {
this.addSettings(new Setting[]{this.mode, this.matrix, this.matrix1, this.matrix2, this.matrix3});
}

public void onEvent(Event event) {
if (!mc.player.isElytraFlying()) {
EventNoSlow eventNoSlow;
if (event instanceof EventNoSlow) {
eventNoSlow = (EventNoSlow)event;
this.handleEventUpdate(eventNoSlow);
} else if (event instanceof EventDamage) {
EventDamage damage = (EventDamage)event;
this.damageUtil.processDamage(damage);
} else if (event instanceof EventPacket) {
EventPacket eventPacket = (EventPacket)event;
if (eventPacket.isReceivePacket()) {
this.damageUtil.onPacketEvent(eventPacket);
}
}

EventPacket e;
IPacket var8;
if (this.matrix.get() && event instanceof EventPacket) {
e = (EventPacket)event;
if (e.isReceivePacket()) {
var8 = e.getPacket();
if (var8 instanceof SHeldItemChangePacket) {
SHeldItemChangePacket packetHeldItemChange = (SHeldItemChangePacket)var8;
if (this.timerUtil.hasTimeElapsed(100L)) {
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem % 8 + 1));
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
this.timerUtil.reset();
}

event.setCancel(true);
}
}
}

if (this.mode.is("Really World")) {
if (this.matrix1.get() && !mc.player.isInWater()) {
return;
}

if (event instanceof EventUpdate) {
if (!this.restart) {
this.restart1 = true;
}

if (this.restart) {
if (this.restart1) {
this.timerUtil.reset();
this.restart1 = false;
}

if (this.timerUtil.hasTimeElapsed(1650L, true)) {
this.restart = false;
}
}
}

if (event instanceof EventPacket) {
e = (EventPacket)event;
if (!this.test && this.timerUtil.hasTimeElapsed(10L)) {
this.test = true;
this.timerUtil.reset();
}

var8 = e.getPacket();
if (var8 instanceof SPlayerPositionLookPacket) {
SPlayerPositionLookPacket p = (SPlayerPositionLookPacket)var8;
this.test = false;
this.timerUtil.reset();
}

if (e.getPacket() instanceof SEntityVelocityPacket && this.test && ((SEntityVelocityPacket)e.getPacket()).getEntityID() == mc.player.getEntityId() && !mc.player.isElytraFlying()) {
if (this.matrix3.get()) {
return;
}

this.restart = false;
this.restart1 = false;
this.restart = true;
this.restart1 = true;
}
}

if (event instanceof EventNoSlow) {
eventNoSlow = (EventNoSlow)event;
if ((mc.player.isInWater() || this.restart) && mc.player.getActiveHand() == Hand.MAIN_HAND && mc.player.getHeldItemOffhand().getUseAction() == UseAction.NONE) {
mc.player.connection.sendPacket(new CPlayerTryUseItemPacket(Hand.OFF_HAND));
eventNoSlow.setCancel(true);
}

if (mc.player.getActiveHand() == Hand.OFF_HAND) {
if (this.matrix2.get() && !mc.player.isInWater() && !this.restart) {
return;
}

mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem % 8 + 1));
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
eventNoSlow.setCancel(true);
}
}
}

}
}

private void handleEventUpdate(EventNoSlow eventNoSlow) {
if (mc.player.isHandActive()) {
switch (this.mode.get()) {
case "Vanilla" -> eventNoSlow.setCancel(true);
case "GrimAC" -> this.handleGrimACMode(eventNoSlow);
}
}

}

private void handleGrimACMode(EventNoSlow noSlow) {
if ((mc.player.getHeldItemOffhand().getUseAction() != UseAction.BLOCK || mc.player.getActiveHand() != Hand.MAIN_HAND) && (mc.player.getHeldItemOffhand().getUseAction() != UseAction.EAT || mc.player.getActiveHand() != Hand.MAIN_HAND)) {
if (mc.player.getActiveHand() == Hand.MAIN_HAND) {
mc.player.connection.sendPacket(new CPlayerTryUseItemPacket(Hand.OFF_HAND));
noSlow.setCancel(true);
} else {
noSlow.setCancel(true);
this.sendItemChangePacket();
}
}
}

private void sendItemChangePacket() {
if (MoveUtil.isMoving()) {
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem % 8 + 1));
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
}

}

protected void onEnable() {
super.onEnable();
this.restart1 = false;
this.restart = false;
}
}
//4
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.combat;

import com.mojang.blaze3d.systems.RenderSystem;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.Iterator;
import java.util.List;
import java.util.concurrent.ThreadLocalRandom;
import net.minecraft.client.renderer.WorldVertexBufferUploader;
import net.minecraft.client.renderer.entity.EntityRendererManager;
import net.minecraft.client.renderer.vertex.DefaultVertexFormats;
import net.minecraft.entity.Entity;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.item.ArmorStandEntity;
import net.minecraft.entity.merchant.villager.VillagerEntity;
import net.minecraft.entity.monster.MonsterEntity;
import net.minecraft.entity.monster.SlimeEntity;
import net.minecraft.entity.passive.AnimalEntity;
import net.minecraft.entity.passive.WaterMobEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.network.play.client.CEntityActionPacket;
import net.minecraft.network.play.client.CHeldItemChangePacket;
import net.minecraft.network.play.client.CEntityActionPacket.Action;
import net.minecraft.potion.Effects;
import net.minecraft.tags.FluidTags;
import net.minecraft.util.Hand;
import net.minecraft.util.math.MathHelper;
import net.minecraft.util.math.vector.Vector3d;
import org.lwjgl.opengl.GL11;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.player.EventInput;
import wtf.expensive.events.impl.player.EventInteractEntity;
import wtf.expensive.events.impl.player.EventMotion;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.events.impl.player.EventWorldChange;
import wtf.expensive.events.impl.render.EventRender;
import wtf.expensive.managment.Managment;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;
import wtf.expensive.modules.settings.Setting;
import wtf.expensive.modules.settings.imp.BooleanOption;
import wtf.expensive.modules.settings.imp.ModeSetting;
import wtf.expensive.modules.settings.imp.MultiBoxSetting;
import wtf.expensive.modules.settings.imp.SliderSetting;
import wtf.expensive.util.ClientUtil;
import wtf.expensive.util.math.GCDUtil;
import wtf.expensive.util.math.RayTraceUtil;
import wtf.expensive.util.movement.MoveUtil;
import wtf.expensive.util.render.RenderUtil.IntColor;
import wtf.expensive.util.world.InventoryUtil;

@FunctionAnnotation(
name = "AuraNew",
type = Type.Combat
)
public class AuraNew extends Function {
private final ModeSetting mode = new ModeSetting("Режим ротации", "Снапы", new String[]{"Обычная", "Снапы"});
private final SliderSetting range = new SliderSetting("Дистанция", 3.0F, 3.0F, 6.0F, 0.05F);
private final SliderSetting preRange = (new SliderSetting("Дистанция ротации", 0.5F, 0.0F, 3.0F, 0.05F)).setVisible(() -> {
return this.mode.is("Обычная");
});
private final MultiBoxSetting targets = new MultiBoxSetting("Цели", new BooleanOption[]{new BooleanOption("Игроки", true), new BooleanOption("Животные", false), new BooleanOption("Монстры", false)});
private final MultiBoxSetting ignore = new MultiBoxSetting("Игнорировать", new BooleanOption[]{new BooleanOption("Друзей", true), new BooleanOption("Невидимых", false), new BooleanOption("Голых", false), new BooleanOption("Ботов", true)});
private final ModeSetting sort = new ModeSetting("Сортировать", "По дистанции", new String[]{"По дистанции", "По здоровью", "По полю зрения"});
public final MultiBoxSetting settings = new MultiBoxSetting("Настройки", new BooleanOption[]{new BooleanOption("Только критами", true), new BooleanOption("Коррекция движения", true), new BooleanOption("Не бить при использовании", false), new BooleanOption("Отжимать щит", true), new BooleanOption("Ломать щит", true)});
private final BooleanOption space = (new BooleanOption("Криты только с пробелом", false)).setVisible(() -> {
return this.settings.get(0);
});
private final BooleanOption silent = (new BooleanOption("Сайлент коррекция", true)).setVisible(() -> {
return this.settings.get(1);
});
private long cpsLimit = 0L;
public static LivingEntity target;
float rotYaw;
float rotPitch;
int ticks;

public AuraNew() {
this.addSettings(new Setting[]{this.range, this.preRange, this.mode, this.targets, this.ignore, this.sort, this.settings, this.space, this.silent});
}

public void onEvent(Event event) {
if (mc.player != null && mc.world != null) {
if (event instanceof EventInteractEntity) {
EventInteractEntity entity = (EventInteractEntity)event;
if (target != null) {
entity.setCancel(true);
}
}

if (event instanceof EventInput) {
EventInput e = (EventInput)event;
if (this.settings.get(1) && this.silent.get()) {
MoveUtil.fixMovement(e, this.rotYaw);
}
}

if (event instanceof EventUpdate) {
target = this.findTarget();
if (target == null) {
this.reset();
return;
}

switch (this.mode.getIndex()) {
case 0:
this.updateRotation(0.5F);
if (this.canAttack() && RayTraceUtil.getMouseOver(target, this.rotYaw, this.rotPitch, (double)this.range.getValue().floatValue()) == target) {
this.updateAttack(target);
}
break;
case 1:
if (this.canAttack()) {
this.updateAttack(target);
this.ticks = 3;
}

if (this.ticks > 0) {
this.updateRotation(1.0F);
--this.ticks;
} else {
this.rotYaw = mc.player.rotationYaw;
this.rotPitch = mc.player.rotationPitch;
}
}
}

if (event instanceof EventMotion) {
EventMotion e = (EventMotion)event;
if (target == null) {
return;
}

e.setYaw(this.rotYaw);
e.setPitch(this.rotPitch);
this.updateClientRotation(this.rotYaw, this.rotPitch);
}

if (event instanceof EventWorldChange) {
this.reset();
}

if (event instanceof EventRender) {
EventRender e = (EventRender)event;
if (e.isRender3D() && target != null) {
}
}

}
}

private void updateRotation(float speed) {
if (!this.isInHitBox(mc.player, target)) {
Vector3d vec3d = this.getVector3d(mc.player, target);
float rawYaw = (float)MathHelper.wrapDegrees(Math.toDegrees(Math.atan2(vec3d.z, vec3d.x)) - 90.0);
float rawPitch = (float)MathHelper.wrapDegrees(Math.toDegrees(-Math.atan2(vec3d.y, Math.hypot(vec3d.x, vec3d.z))));
float yawDelta = MathHelper.wrapDegrees(rawYaw - this.rotYaw);
float pitchDelta = MathHelper.wrapDegrees(rawPitch - this.rotPitch);
if (Math.abs(yawDelta) > 180.0F) {
yawDelta -= Math.signum(yawDelta) * 360.0F;
}

float additionYaw = MathHelper.clamp(yawDelta, -180.0F * speed, 180.0F * speed);
float additionPitch = MathHelper.clamp(pitchDelta, -90.0F * speed, 90.0F * speed);
float yaw = this.rotYaw + additionYaw + ThreadLocalRandom.current().nextFloat(-1.0F, 1.0F);
float pitch = this.rotPitch + additionPitch + ThreadLocalRandom.current().nextFloat(-1.0F, 1.0F);
this.rotYaw = GCDUtil.getSensitivity(yaw);
this.rotPitch = GCDUtil.getSensitivity(MathHelper.clamp(pitch, -89.0F, 89.0F));
}
}

private void updateAttack(LivingEntity target) {
if (mc.player.isHandActive()) {
if (this.settings.get(3) && mc.player.isActiveItemStackBlocking()) {
mc.playerController.onStoppedUsingItem(mc.player);
} else if (this.settings.get(2)) {
return;
}
}

boolean sprint = false;
if (this.settings.get(0) && CEntityActionPacket.lastUpdatedSprint) {
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.STOP_SPRINTING));
if (!mc.player.isInWater()) {
mc.player.setSprinting(false);
}

sprint = true;
}

this.cpsLimit = System.currentTimeMillis() + 550L;
this.attackEntity(target);
if (this.settings.get(4) && target.isBlocking()) {
int slot = InventoryUtil.getAxe(true);
if (slot == -1) {
return;
}

mc.player.connection.sendPacket(new CHeldItemChangePacket(slot));
this.attackEntity(target);
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
ClientUtil.sendMesage("БРЯК: " + mc.player.ticksExisted);
}

if (sprint) {
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_SPRINTING));
}

}

private boolean canAttack() {
if (this.cpsLimit < System.currentTimeMillis() && !Managment.FUNCTION_MANAGER.autoPotionFunction.isActivePotion && !(this.getDistance(target) >= (double)this.range.getValue().floatValue()) && !(mc.player.getCooledAttackStrength(1.0F) <= 0.93F)) {
if ((!mc.player.isInWater() || !mc.player.areEyesInFluid(FluidTags.WATER)) && !mc.player.isInLava() && !mc.player.isOnLadder() && !mc.player.isRidingHorse() && !mc.player.abilities.isFlying && !mc.player.isElytraFlying() && !mc.player.isPotionActive(Effects.LEVITATION) && !mc.player.isPotionActive(Effects.SLOW_FALLING) && this.settings.get(0)) {
return this.space.get() && !mc.player.movementInput.jump || mc.player.fallDistance > 0.0F && !mc.player.isOnGround();
} else {
return true;
}
} else {
return false;
}
}

private LivingEntity findTarget() {
List<LivingEntity> targets = new ArrayList();
Iterator var2 = mc.world.getAllEntities().iterator();

while(true) {
LivingEntity living;
do {
do {
do {
do {
do {
do {
do {
Entity entity;
do {
if (!var2.hasNext()) {
if (targets.isEmpty()) {
return null;
}

if (targets.size() == 1) {
return (LivingEntity)targets.get(0);
}

Comparator var10001;
switch (this.sort.getIndex()) {
case 0 -> var10001 = Comparator.comparingDouble(this::getDistance);
case 1 -> var10001 = Comparator.comparingDouble(LivingEntity::getHealth);
case 2 -> var10001 = Comparator.comparingDouble(this::getDegree);
default -> var10001 = null;
}

return (LivingEntity)Collections.min(targets, var10001);
}

entity = (Entity)var2.next();
} while(!(entity instanceof LivingEntity));

living = (LivingEntity)entity;
} while(!this.isValid(living));
} while(!(this.getDistance(living) <= (double)(this.range.getValue().floatValue() + (this.mode.is("Обычная") ? this.preRange.getValue().floatValue() : 0.0F))));
} while(this.ignore.get(0) && Managment.FRIEND_MANAGER.isFriend(living.getName().getString()));
} while(this.ignore.get(1) && living.isInvisible());
} while((double)living.getHealth() < 0.01);
} while(this.ignore.get(2) && living instanceof PlayerEntity && living.getTotalArmorValue() == 0);
} while(this.ignore.get(3) && living instanceof PlayerEntity && !living.getUniqueID().equals(PlayerEntity.getOfflineUUID(living.getName().getString())));

targets.add(living);
}
}

private boolean isValid(LivingEntity entity) {
if (!(entity instanceof ArmorStandEntity) && entity != mc.player) {
if (entity instanceof PlayerEntity) {
return this.targets.get(0);
} else if (!(entity instanceof AnimalEntity) && !(entity instanceof VillagerEntity) && !(entity instanceof WaterMobEntity)) {
return !(entity instanceof MonsterEntity) && !(entity instanceof SlimeEntity) ? true : this.targets.get(2);
} else {
return this.targets.get(1);
}
} else {
return false;
}
}

private void updateClientRotation(float yaw, float pitch) {
mc.player.rotationYawHead = yaw;
mc.player.renderYawOffset = yaw;
mc.player.rotationPitchHead = pitch;
}

private void reset() {
this.rotYaw = mc.player.rotationYaw;
this.rotPitch = mc.player.rotationPitch;
target = null;
}

private void attackEntity(LivingEntity entity) {
mc.playerController.attackEntity(mc.player, entity);
mc.player.swingArm(Hand.MAIN_HAND);
}

private boolean isInHitBox(LivingEntity me, LivingEntity to) {
double wHalf = (double)(to.getWidth() / 2.0F);
double yExpand = MathHelper.clamp(me.getPosYEye() - to.getPosY(), 0.0, (double)to.getHeight());
double xExpand = MathHelper.clamp(mc.player.getPosX() - to.getPosX(), -wHalf, wHalf);
double zExpand = MathHelper.clamp(mc.player.getPosZ() - to.getPosZ(), -wHalf, wHalf);
return (new Vector3d(to.getPosX() - me.getPosX() + xExpand, to.getPosY() - me.getPosYEye() + yExpand, to.getPosZ() - me.getPosZ() + zExpand)).length() == 0.0;
}

private Vector3d getVector3d(LivingEntity me, LivingEntity to) {
double wHalf = (double)(to.getWidth() / 2.0F);
double yExpand = MathHelper.clamp(me.getPosYEye() - to.getPosY(), 0.0, (double)(to.getHeight() * (mc.player.getDistance(to) / this.range.getValue().floatValue())));
double xExpand = MathHelper.clamp(mc.player.getPosX() - to.getPosX(), -wHalf, wHalf);
double zExpand = MathHelper.clamp(mc.player.getPosZ() - to.getPosZ(), -wHalf, wHalf);
return new Vector3d(to.getPosX() - me.getPosX() + xExpand, to.getPosY() - me.getPosYEye() + yExpand, to.getPosZ() - me.getPosZ() + zExpand);
}

private double getDistance(LivingEntity entity) {
return this.getVector3d(mc.player, entity).length();
}

private double getDegree(LivingEntity entity) {
Vector3d vec = this.getVector3d(mc.player, entity);
double yaw = MathHelper.wrapDegrees(Math.toDegrees(Math.atan2(vec.z, vec.x)) - 90.0);
double delta = MathHelper.wrapDegrees(yaw - (double)mc.player.rotationYaw);
if (Math.abs(delta) > 180.0) {
delta -= Math.signum(delta) * 360.0;
}

return Math.abs(delta);
}

private boolean isLookingAtMe(LivingEntity target) {
double x = target.getPosX() - mc.player.getPosX();
double z = target.getPosZ() - mc.player.getPosZ();
float entityYaw = MathHelper.wrapDegrees(target.rotationYaw);
double yaw = Math.toDegrees(Math.atan2(z, x)) + 90.0;
return Math.abs(MathHelper.wrapDegrees(yaw - (double)entityYaw)) <= 90.0;
}

private void drawCircle(LivingEntity target, EventRender e) {
EntityRendererManager rm = mc.getRenderManager();
double x = target.lastTickPosX + (target.getPosX() - target.lastTickPosX) * (double)e.partialTicks - rm.info.getProjectedView().getX();
double y = target.lastTickPosY + (target.getPosY() - target.lastTickPosY) * (double)e.partialTicks - rm.info.getProjectedView().getY();
double z = target.lastTickPosZ + (target.getPosZ() - target.lastTickPosZ) * (double)e.partialTicks - rm.info.getProjectedView().getZ();
float height = target.getHeight();
double duration = 2000.0;
double elapsed = (double)System.currentTimeMillis() % duration;
boolean side = elapsed > duration / 2.0;
double progress = elapsed / (duration / 2.0);
if (side) {
--progress;
} else {
progress = 1.0 - progress;
}

progress = progress < 0.5 ? 2.0 * progress * progress : 1.0 - Math.pow(-2.0 * progress + 2.0, 2.0) / 2.0;
double eased = (double)(height / 2.0F) * (progress > 0.5 ? 1.0 - progress : progress) * (double)(side ? -1 : 1);
RenderSystem.pushMatrix();
GL11.glDepthMask(false);
GL11.glEnable(2848);
GL11.glHint(3154, 4354);
RenderSystem.disableTexture();
RenderSystem.enableBlend();
RenderSystem.disableAlphaTest();
RenderSystem.shadeModel(7425);
RenderSystem.disableCull();
RenderSystem.lineWidth(1.5F);
RenderSystem.color4f(-1.0F, -1.0F, -1.0F, -1.0F);
buffer.begin(8, DefaultVertexFormats.POSITION_COLOR);
float[] colors = null;

int i;
for(i = 0; i <= 360; ++i) {
colors = IntColor.rgb(Managment.STYLE_MANAGER.getCurrentStyle().getColor(i));
buffer.pos(x + Math.cos(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8, y + (double)height * progress, z + Math.sin(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8).color(colors[0], colors[1], colors[2], 0.5F).endVertex();
buffer.pos(x + Math.cos(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8, y + (double)height * progress + eased, z + Math.sin(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8).color(colors[0], colors[1], colors[2], 0.0F).endVertex();
}

buffer.finishDrawing();
WorldVertexBufferUploader.draw(buffer);
RenderSystem.color4f(-1.0F, -1.0F, -1.0F, -1.0F);
buffer.begin(2, DefaultVertexFormats.POSITION_COLOR);

for(i = 0; i <= 360; ++i) {
buffer.pos(x + Math.cos(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8, y + (double)height * progress, z + Math.sin(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8).color(colors[0], colors[1], colors[2], 0.5F).endVertex();
}

buffer.finishDrawing();
WorldVertexBufferUploader.draw(buffer);
RenderSystem.enableCull();
RenderSystem.disableBlend();
RenderSystem.enableTexture();
RenderSystem.enableAlphaTest();
GL11.glDepthMask(true);
GL11.glDisable(2848);
GL11.glHint(3154, 4354);
RenderSystem.shadeModel(7424);
RenderSystem.popMatrix();
}

protected void onDisable() {
super.onDisable();
this.reset();
}

protected void onEnable() {
super.onEnable();
this.reset();
}

public static LivingEntity getTarget() {
return target;
}

public float getRotYaw() {
return this.rotYaw;
}

public float getRotPitch() {
return this.rotPitch;
}
}

//5
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.movement;

import java.util.Iterator;
import net.minecraft.entity.Entity;
import net.minecraft.entity.item.ItemEntity;
import net.minecraft.item.ElytraItem;
import net.minecraft.item.SkullItem;
import net.minecraft.item.SpawnEggItem;
import net.minecraft.util.math.MathHelper;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;

@FunctionAnnotation(
name = "AutoPilot",
type = Type.Movement
)
public class AutoPilot extends Function {
public AutoPilot() {
}

public void onEvent(Event event) {
boolean skullItemNoNull = false;
boolean eggItemNoNull = false;
boolean elytraItemNoNull = false;
Iterator var5;
Entity entity;
if (event instanceof EventUpdate) {
var5 = mc.world.getAllEntities().iterator();

while(var5.hasNext()) {
entity = (Entity)var5.next();
if (entity instanceof ItemEntity) {
if (((ItemEntity)entity).getItem().getItem() instanceof SkullItem) {
skullItemNoNull = true;
}

if (((ItemEntity)entity).getItem().getItem() instanceof ElytraItem) {
elytraItemNoNull = true;
}

if (((ItemEntity)entity).getItem().getItem() instanceof SpawnEggItem) {
eggItemNoNull = true;
}
}
}
}

if (event instanceof EventUpdate) {
var5 = mc.world.getAllEntities().iterator();

while(var5.hasNext()) {
entity = (Entity)var5.next();
if (entity instanceof ItemEntity) {
if (((ItemEntity)entity).getItem().getItem() instanceof SkullItem) {
mc.player.rotationYaw = this.rotations(entity)[0];
mc.player.rotationPitch = this.rotations(entity)[1];
break;
}

if (((ItemEntity)entity).getItem().getItem() instanceof ElytraItem && !skullItemNoNull) {
mc.player.rotationYaw = this.rotations(entity)[0];
mc.player.rotationPitch = this.rotations(entity)[1];
break;
}

if (((ItemEntity)entity).getItem().getItem() instanceof SpawnEggItem && !elytraItemNoNull && !skullItemNoNull) {
mc.player.rotationYaw = this.rotations(entity)[0];
mc.player.rotationPitch = this.rotations(entity)[1];
break;
}
}
}

skullItemNoNull = true;
elytraItemNoNull = true;
eggItemNoNull = true;
}

}

public float[] rotations(Entity entity) {
double x = entity.getPosX() - mc.player.getPosX();
double y = entity.getPosY() - mc.player.getPosY() - 1.5;
double z = entity.getPosZ() - mc.player.getPosZ();
double u = (double)MathHelper.sqrt(x * x + z * z);
float u2 = (float)(MathHelper.atan2(z, x) * 57.29577951308232 - 90.0);
float u3 = (float)(-MathHelper.atan2(y, u) * 57.29577951308232);
return new float[]{u2, u3};
}
}
 
Забаненный
Статус
Оффлайн
Регистрация
5 Май 2024
Сообщения
44
Реакции[?]
0
Поинты[?]
0
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Начинающий
Статус
Оффлайн
Регистрация
8 Апр 2023
Сообщения
219
Реакции[?]
20
Поинты[?]
23K
//1
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package im.expensive.modules.impl.movement;

import net.minecraft.inventory.container.ClickType;
import net.minecraft.item.ItemStack;
import net.minecraft.item.Items;
import net.minecraft.network.play.client.CEntityActionPacket;
import net.minecraft.network.play.client.CEntityActionPacket.Action;
import net.minecraft.network.play.server.SEntityMetadataPacket;
import net.minecraft.util.Hand;
import net.minecraft.util.text.TextFormatting;
import im.expensive.events.Event;
import im.expensive.events.impl.packet.EventPacket;
import im.expensive.events.impl.player.EventMotion;
import im.expensive.events.impl.player.EventUpdate;
import im.expensive.modules.Function;
import im.expensive.modules.FunctionAnnotation;
import im.expensive.modules.Type;
import im.expensive.modules.settings.Setting;
import im.expensive.modules.settings.imp.BooleanOption;
import im.expensive.modules.settings.imp.SliderSetting;
import im.expensive.util.ClientUtil;
import im.expensive.util.misc.TimerUtil;
import im.expensive.util.movement.MoveUtil;
import im.expensive.util.world.InventoryUtil;

@FunctionAnnotation(
name = "CatStrafe",
type = Type.Movement
)
public class CatStrafe extends Function {
private final TimerUtil timerUtil = new TimerUtil();
int oldItem = -1;
private final SliderSetting speedBoost = new SliderSetting("Скорость", 0.3F, 0.0F, 0.8F, 1.0E-4F);
private final BooleanOption autoJump = new BooleanOption("Авто прыжок", false);
private final BooleanOption safeMode = new BooleanOption("Безопасный режим", false);
boolean test1 = false;

public CatStrafe() {
this.addSettings(new Setting[]{this.speedBoost, this.safeMode, this.autoJump});
}

protected void onEnable() {
super.onEnable();
}

public void onEvent(Event event) {
if (event instanceof EventUpdate) {
if (mc.player.collidedHorizontally && this.safeMode.get()) {
ClientUtil.sendMesage(TextFormatting.RED + "Вы столкнулись с блоком, перезапустите функцию!");
this.toggle();
return;
}

if (InventoryUtil.getItemSlot(Items.FIREWORK_ROCKET) == -1 || mc.player.collidedHorizontally || !InventoryUtil.doesHotbarHaveItem(Items.ELYTRA)) {
return;
}

if (this.autoJump.get() && !mc.gameSettings.keyBindJump.isKeyDown() && mc.player.isOnGround()) {
mc.gameSettings.keyBindJump.setPressed(true);
}

if (mc.player.getActiveHand() == Hand.MAIN_HAND) {
mc.playerController.onStoppedUsingItem(mc.player);
}
}

if (event instanceof EventMotion eventMotion) {
eventMotion.setPitch(15.0F);
mc.player.rotationPitchHead = 15.0F;
}

if (event instanceof EventUpdate) {
mc.gameSettings.keyBindBack.setPressed(false);
mc.gameSettings.keyBindLeft.setPressed(false);
mc.gameSettings.keyBindRight.setPressed(false);
boolean test = false;
if ((mc.player.isOnGround() || mc.player.fallDistance != 0.0F && mc.gameSettings.keyBindJump.isKeyDown()) && this.timerUtil.hasTimeElapsed(600L)) {
test = true;
}

if (mc.player.isOnGround() && test) {
mc.gameSettings.keyBindForward.setPressed(false);
return;
}

if (mc.player.fallDistance == 0.0F && !mc.player.isOnGround()) {
test = false;
}

for(int i = 0; i < 9; ++i) {
if (mc.player.inventory.getStackInSlot(i).getItem() == Items.ELYTRA && !mc.player.isOnGround() && !mc.player.isInWater() && !mc.player.isInLava()) {
float speed;
if (InventoryUtil.doesHotbarHaveItem(Items.FIREWORK_ROCKET) && this.timerUtil.hasTimeElapsed(300L)) {
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_FALL_FLYING));
speed = 0.9F + this.speedBoost.getValue().floatValue();
MoveUtil.setMotion((double)speed);
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
if (this.timerUtil.hasTimeElapsed(300L)) {
InventoryUtil.inventorySwapClick(Items.FIREWORK_ROCKET, false);
this.timerUtil.reset();
}
}

if (!InventoryUtil.doesHotbarHaveItem(Items.FIREWORK_ROCKET) && this.timerUtil.hasTimeElapsed(300L)) {
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_FALL_FLYING));
speed = 0.9F + this.speedBoost.getValue().floatValue();
MoveUtil.setMotion((double)speed);
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
if (this.timerUtil.hasTimeElapsed(300L)) {
InventoryUtil.inventorySwapClick(Items.FIREWORK_ROCKET, false);
this.timerUtil.reset();
}
}
}
}
}

if (event instanceof EventPacket e) {
if (e.getPacket() instanceof SEntityMetadataPacket && ((SEntityMetadataPacket)e.getPacket()).getEntityId() == mc.player.getEntityId()) {
e.setCancel(true);
}
}

}

public void onDisable() {
super.onDisable();
if (this.oldItem != -1) {
if (((ItemStack)mc.player.inventory.armorInventory.get(2)).getItem() == Items.ELYTRA) {
mc.playerController.windowClick(0, this.oldItem < 9 ? this.oldItem + 36 : this.oldItem, 38, ClickType.SWAP, mc.player);
}

this.oldItem = -1;
}

}
}
//2
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.movement;

import net.minecraft.block.Blocks;
import net.minecraft.inventory.container.ClickType;
import net.minecraft.item.Items;
import net.minecraft.item.UseAction;
import net.minecraft.network.play.client.CEntityActionPacket;
import net.minecraft.network.play.client.CEntityActionPacket.Action;
import net.minecraft.util.Hand;
import net.minecraft.util.math.BlockPos;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;
import wtf.expensive.modules.settings.Setting;
import wtf.expensive.modules.settings.imp.BooleanOption;
import wtf.expensive.modules.settings.imp.SliderSetting;
import wtf.expensive.util.misc.TimerUtil;
import wtf.expensive.util.world.InventoryUtil;

@FunctionAnnotation(
name = "CatFly",
type = Type.Movement
)
public class CatFly extends Function {
private final TimerUtil timerUtil = new TimerUtil();
private final TimerUtil timerUtil1 = new TimerUtil();
private final SliderSetting timerStartFireWork = new SliderSetting("Таймер фейерверка", 400.0F, 50.0F, 1500.0F, 1.0F);
private final BooleanOption onlyGrimBypass = new BooleanOption("Обходить только грим", false);
private final BooleanOption noFireWorkifEat = new BooleanOption("Отсутствие еды в правой руке", false);

public CatFly() {
this.addSettings(new Setting[]{this.timerStartFireWork, this.onlyGrimBypass, this.noFireWorkifEat});
}

public void onEvent(Event event) {
if (InventoryUtil.getItemSlot(Items.FIREWORK_ROCKET) != -1) {
if (event instanceof EventUpdate) {
int timeSwap = 200;
if (this.onlyGrimBypass.get()) {
timeSwap = 0;
}

boolean startFireWork = true;
if (this.noFireWorkifEat.get() && mc.player.getActiveHand() == Hand.MAIN_HAND && mc.player.getHeldItemMainhand().getUseAction() == UseAction.EAT) {
startFireWork = false;
}

for(int i = 0; i < 9; ++i) {
if (mc.player.inventory.getStackInSlot(i).getItem() == Items.ELYTRA && mc.world.getBlockState(new BlockPos(mc.player.getPosX(), mc.player.getPosY() - 0.01, mc.player.getPosZ())).getBlock() == Blocks.AIR && !mc.player.isOnGround() && !mc.player.isInWater() && !mc.player.isInLava() && !mc.player.isElytraFlying()) {
if (this.timerUtil1.hasTimeElapsed((long)timeSwap)) {
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
mc.player.startFallFlying();
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_FALL_FLYING));
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
this.timerUtil1.reset();
}

if (this.timerUtil.hasTimeElapsed((long)this.timerStartFireWork.getValue().intValue()) && mc.player.isElytraFlying()) {
if (startFireWork) {
InventoryUtil.inventorySwapClick(Items.FIREWORK_ROCKET, false);
}

this.timerUtil.reset();
}
}
}
}

}
}

public void onDisable() {
super.onDisable();
}
}

//3
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.movement;

import net.minecraft.item.UseAction;
import net.minecraft.network.IPacket;
import net.minecraft.network.play.client.CHeldItemChangePacket;
import net.minecraft.network.play.client.CPlayerTryUseItemPacket;
import net.minecraft.network.play.server.SEntityVelocityPacket;
import net.minecraft.network.play.server.SHeldItemChangePacket;
import net.minecraft.network.play.server.SPlayerPositionLookPacket;
import net.minecraft.util.Hand;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.packet.EventPacket;
import wtf.expensive.events.impl.player.EventDamage;
import wtf.expensive.events.impl.player.EventNoSlow;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;
import wtf.expensive.modules.settings.Setting;
import wtf.expensive.modules.settings.imp.BooleanOption;
import wtf.expensive.modules.settings.imp.ModeSetting;
import wtf.expensive.util.misc.DamageUtil;
import wtf.expensive.util.misc.TimerUtil;
import wtf.expensive.util.movement.MoveUtil;

@FunctionAnnotation(
name = "NoSlow",
type = Type.Movement
)
public class NoSlowFunction extends Function {
public ModeSetting mode = new ModeSetting("Мод", "Really World", new String[]{"Vanilla", "Really World", "GrimAC"});
private DamageUtil damageUtil = new DamageUtil();
public TimerUtil timerUtil = new TimerUtil();
public BooleanOption matrix = new BooleanOption("Фикс свапа", true);
public BooleanOption matrix1 = (new BooleanOption("Работать только в воде", true)).setVisible(() -> {
return this.mode.is("Really World");
});
public BooleanOption matrix2 = (new BooleanOption("Работать только от урона", true)).setVisible(() -> {
return this.mode.is("Really World");
});
public BooleanOption matrix3 = (new BooleanOption("Выключить работать от урона", true)).setVisible(() -> {
return this.mode.is("Really World");
});
boolean restart = false;
boolean restart1 = false;
boolean test = true;

public NoSlowFunction() {
this.addSettings(new Setting[]{this.mode, this.matrix, this.matrix1, this.matrix2, this.matrix3});
}

public void onEvent(Event event) {
if (!mc.player.isElytraFlying()) {
EventNoSlow eventNoSlow;
if (event instanceof EventNoSlow) {
eventNoSlow = (EventNoSlow)event;
this.handleEventUpdate(eventNoSlow);
} else if (event instanceof EventDamage) {
EventDamage damage = (EventDamage)event;
this.damageUtil.processDamage(damage);
} else if (event instanceof EventPacket) {
EventPacket eventPacket = (EventPacket)event;
if (eventPacket.isReceivePacket()) {
this.damageUtil.onPacketEvent(eventPacket);
}
}

EventPacket e;
IPacket var8;
if (this.matrix.get() && event instanceof EventPacket) {
e = (EventPacket)event;
if (e.isReceivePacket()) {
var8 = e.getPacket();
if (var8 instanceof SHeldItemChangePacket) {
SHeldItemChangePacket packetHeldItemChange = (SHeldItemChangePacket)var8;
if (this.timerUtil.hasTimeElapsed(100L)) {
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem % 8 + 1));
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
this.timerUtil.reset();
}

event.setCancel(true);
}
}
}

if (this.mode.is("Really World")) {
if (this.matrix1.get() && !mc.player.isInWater()) {
return;
}

if (event instanceof EventUpdate) {
if (!this.restart) {
this.restart1 = true;
}

if (this.restart) {
if (this.restart1) {
this.timerUtil.reset();
this.restart1 = false;
}

if (this.timerUtil.hasTimeElapsed(1650L, true)) {
this.restart = false;
}
}
}

if (event instanceof EventPacket) {
e = (EventPacket)event;
if (!this.test && this.timerUtil.hasTimeElapsed(10L)) {
this.test = true;
this.timerUtil.reset();
}

var8 = e.getPacket();
if (var8 instanceof SPlayerPositionLookPacket) {
SPlayerPositionLookPacket p = (SPlayerPositionLookPacket)var8;
this.test = false;
this.timerUtil.reset();
}

if (e.getPacket() instanceof SEntityVelocityPacket && this.test && ((SEntityVelocityPacket)e.getPacket()).getEntityID() == mc.player.getEntityId() && !mc.player.isElytraFlying()) {
if (this.matrix3.get()) {
return;
}

this.restart = false;
this.restart1 = false;
this.restart = true;
this.restart1 = true;
}
}

if (event instanceof EventNoSlow) {
eventNoSlow = (EventNoSlow)event;
if ((mc.player.isInWater() || this.restart) && mc.player.getActiveHand() == Hand.MAIN_HAND && mc.player.getHeldItemOffhand().getUseAction() == UseAction.NONE) {
mc.player.connection.sendPacket(new CPlayerTryUseItemPacket(Hand.OFF_HAND));
eventNoSlow.setCancel(true);
}

if (mc.player.getActiveHand() == Hand.OFF_HAND) {
if (this.matrix2.get() && !mc.player.isInWater() && !this.restart) {
return;
}

mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem % 8 + 1));
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
eventNoSlow.setCancel(true);
}
}
}

}
}

private void handleEventUpdate(EventNoSlow eventNoSlow) {
if (mc.player.isHandActive()) {
switch (this.mode.get()) {
case "Vanilla" -> eventNoSlow.setCancel(true);
case "GrimAC" -> this.handleGrimACMode(eventNoSlow);
}
}

}

private void handleGrimACMode(EventNoSlow noSlow) {
if ((mc.player.getHeldItemOffhand().getUseAction() != UseAction.BLOCK || mc.player.getActiveHand() != Hand.MAIN_HAND) && (mc.player.getHeldItemOffhand().getUseAction() != UseAction.EAT || mc.player.getActiveHand() != Hand.MAIN_HAND)) {
if (mc.player.getActiveHand() == Hand.MAIN_HAND) {
mc.player.connection.sendPacket(new CPlayerTryUseItemPacket(Hand.OFF_HAND));
noSlow.setCancel(true);
} else {
noSlow.setCancel(true);
this.sendItemChangePacket();
}
}
}

private void sendItemChangePacket() {
if (MoveUtil.isMoving()) {
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem % 8 + 1));
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
}

}

protected void onEnable() {
super.onEnable();
this.restart1 = false;
this.restart = false;
}
}
//4
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.combat;

import com.mojang.blaze3d.systems.RenderSystem;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.Iterator;
import java.util.List;
import java.util.concurrent.ThreadLocalRandom;
import net.minecraft.client.renderer.WorldVertexBufferUploader;
import net.minecraft.client.renderer.entity.EntityRendererManager;
import net.minecraft.client.renderer.vertex.DefaultVertexFormats;
import net.minecraft.entity.Entity;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.item.ArmorStandEntity;
import net.minecraft.entity.merchant.villager.VillagerEntity;
import net.minecraft.entity.monster.MonsterEntity;
import net.minecraft.entity.monster.SlimeEntity;
import net.minecraft.entity.passive.AnimalEntity;
import net.minecraft.entity.passive.WaterMobEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.network.play.client.CEntityActionPacket;
import net.minecraft.network.play.client.CHeldItemChangePacket;
import net.minecraft.network.play.client.CEntityActionPacket.Action;
import net.minecraft.potion.Effects;
import net.minecraft.tags.FluidTags;
import net.minecraft.util.Hand;
import net.minecraft.util.math.MathHelper;
import net.minecraft.util.math.vector.Vector3d;
import org.lwjgl.opengl.GL11;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.player.EventInput;
import wtf.expensive.events.impl.player.EventInteractEntity;
import wtf.expensive.events.impl.player.EventMotion;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.events.impl.player.EventWorldChange;
import wtf.expensive.events.impl.render.EventRender;
import wtf.expensive.managment.Managment;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;
import wtf.expensive.modules.settings.Setting;
import wtf.expensive.modules.settings.imp.BooleanOption;
import wtf.expensive.modules.settings.imp.ModeSetting;
import wtf.expensive.modules.settings.imp.MultiBoxSetting;
import wtf.expensive.modules.settings.imp.SliderSetting;
import wtf.expensive.util.ClientUtil;
import wtf.expensive.util.math.GCDUtil;
import wtf.expensive.util.math.RayTraceUtil;
import wtf.expensive.util.movement.MoveUtil;
import wtf.expensive.util.render.RenderUtil.IntColor;
import wtf.expensive.util.world.InventoryUtil;

@FunctionAnnotation(
name = "AuraNew",
type = Type.Combat
)
public class AuraNew extends Function {
private final ModeSetting mode = new ModeSetting("Режим ротации", "Снапы", new String[]{"Обычная", "Снапы"});
private final SliderSetting range = new SliderSetting("Дистанция", 3.0F, 3.0F, 6.0F, 0.05F);
private final SliderSetting preRange = (new SliderSetting("Дистанция ротации", 0.5F, 0.0F, 3.0F, 0.05F)).setVisible(() -> {
return this.mode.is("Обычная");
});
private final MultiBoxSetting targets = new MultiBoxSetting("Цели", new BooleanOption[]{new BooleanOption("Игроки", true), new BooleanOption("Животные", false), new BooleanOption("Монстры", false)});
private final MultiBoxSetting ignore = new MultiBoxSetting("Игнорировать", new BooleanOption[]{new BooleanOption("Друзей", true), new BooleanOption("Невидимых", false), new BooleanOption("Голых", false), new BooleanOption("Ботов", true)});
private final ModeSetting sort = new ModeSetting("Сортировать", "По дистанции", new String[]{"По дистанции", "По здоровью", "По полю зрения"});
public final MultiBoxSetting settings = new MultiBoxSetting("Настройки", new BooleanOption[]{new BooleanOption("Только критами", true), new BooleanOption("Коррекция движения", true), new BooleanOption("Не бить при использовании", false), new BooleanOption("Отжимать щит", true), new BooleanOption("Ломать щит", true)});
private final BooleanOption space = (new BooleanOption("Криты только с пробелом", false)).setVisible(() -> {
return this.settings.get(0);
});
private final BooleanOption silent = (new BooleanOption("Сайлент коррекция", true)).setVisible(() -> {
return this.settings.get(1);
});
private long cpsLimit = 0L;
public static LivingEntity target;
float rotYaw;
float rotPitch;
int ticks;

public AuraNew() {
this.addSettings(new Setting[]{this.range, this.preRange, this.mode, this.targets, this.ignore, this.sort, this.settings, this.space, this.silent});
}

public void onEvent(Event event) {
if (mc.player != null && mc.world != null) {
if (event instanceof EventInteractEntity) {
EventInteractEntity entity = (EventInteractEntity)event;
if (target != null) {
entity.setCancel(true);
}
}

if (event instanceof EventInput) {
EventInput e = (EventInput)event;
if (this.settings.get(1) && this.silent.get()) {
MoveUtil.fixMovement(e, this.rotYaw);
}
}

if (event instanceof EventUpdate) {
target = this.findTarget();
if (target == null) {
this.reset();
return;
}

switch (this.mode.getIndex()) {
case 0:
this.updateRotation(0.5F);
if (this.canAttack() && RayTraceUtil.getMouseOver(target, this.rotYaw, this.rotPitch, (double)this.range.getValue().floatValue()) == target) {
this.updateAttack(target);
}
break;
case 1:
if (this.canAttack()) {
this.updateAttack(target);
this.ticks = 3;
}

if (this.ticks > 0) {
this.updateRotation(1.0F);
--this.ticks;
} else {
this.rotYaw = mc.player.rotationYaw;
this.rotPitch = mc.player.rotationPitch;
}
}
}

if (event instanceof EventMotion) {
EventMotion e = (EventMotion)event;
if (target == null) {
return;
}

e.setYaw(this.rotYaw);
e.setPitch(this.rotPitch);
this.updateClientRotation(this.rotYaw, this.rotPitch);
}

if (event instanceof EventWorldChange) {
this.reset();
}

if (event instanceof EventRender) {
EventRender e = (EventRender)event;
if (e.isRender3D() && target != null) {
}
}

}
}

private void updateRotation(float speed) {
if (!this.isInHitBox(mc.player, target)) {
Vector3d vec3d = this.getVector3d(mc.player, target);
float rawYaw = (float)MathHelper.wrapDegrees(Math.toDegrees(Math.atan2(vec3d.z, vec3d.x)) - 90.0);
float rawPitch = (float)MathHelper.wrapDegrees(Math.toDegrees(-Math.atan2(vec3d.y, Math.hypot(vec3d.x, vec3d.z))));
float yawDelta = MathHelper.wrapDegrees(rawYaw - this.rotYaw);
float pitchDelta = MathHelper.wrapDegrees(rawPitch - this.rotPitch);
if (Math.abs(yawDelta) > 180.0F) {
yawDelta -= Math.signum(yawDelta) * 360.0F;
}

float additionYaw = MathHelper.clamp(yawDelta, -180.0F * speed, 180.0F * speed);
float additionPitch = MathHelper.clamp(pitchDelta, -90.0F * speed, 90.0F * speed);
float yaw = this.rotYaw + additionYaw + ThreadLocalRandom.current().nextFloat(-1.0F, 1.0F);
float pitch = this.rotPitch + additionPitch + ThreadLocalRandom.current().nextFloat(-1.0F, 1.0F);
this.rotYaw = GCDUtil.getSensitivity(yaw);
this.rotPitch = GCDUtil.getSensitivity(MathHelper.clamp(pitch, -89.0F, 89.0F));
}
}

private void updateAttack(LivingEntity target) {
if (mc.player.isHandActive()) {
if (this.settings.get(3) && mc.player.isActiveItemStackBlocking()) {
mc.playerController.onStoppedUsingItem(mc.player);
} else if (this.settings.get(2)) {
return;
}
}

boolean sprint = false;
if (this.settings.get(0) && CEntityActionPacket.lastUpdatedSprint) {
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.STOP_SPRINTING));
if (!mc.player.isInWater()) {
mc.player.setSprinting(false);
}

sprint = true;
}

this.cpsLimit = System.currentTimeMillis() + 550L;
this.attackEntity(target);
if (this.settings.get(4) && target.isBlocking()) {
int slot = InventoryUtil.getAxe(true);
if (slot == -1) {
return;
}

mc.player.connection.sendPacket(new CHeldItemChangePacket(slot));
this.attackEntity(target);
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
ClientUtil.sendMesage("БРЯК: " + mc.player.ticksExisted);
}

if (sprint) {
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_SPRINTING));
}

}

private boolean canAttack() {
if (this.cpsLimit < System.currentTimeMillis() && !Managment.FUNCTION_MANAGER.autoPotionFunction.isActivePotion && !(this.getDistance(target) >= (double)this.range.getValue().floatValue()) && !(mc.player.getCooledAttackStrength(1.0F) <= 0.93F)) {
if ((!mc.player.isInWater() || !mc.player.areEyesInFluid(FluidTags.WATER)) && !mc.player.isInLava() && !mc.player.isOnLadder() && !mc.player.isRidingHorse() && !mc.player.abilities.isFlying && !mc.player.isElytraFlying() && !mc.player.isPotionActive(Effects.LEVITATION) && !mc.player.isPotionActive(Effects.SLOW_FALLING) && this.settings.get(0)) {
return this.space.get() && !mc.player.movementInput.jump || mc.player.fallDistance > 0.0F && !mc.player.isOnGround();
} else {
return true;
}
} else {
return false;
}
}

private LivingEntity findTarget() {
List<LivingEntity> targets = new ArrayList();
Iterator var2 = mc.world.getAllEntities().iterator();

while(true) {
LivingEntity living;
do {
do {
do {
do {
do {
do {
do {
Entity entity;
do {
if (!var2.hasNext()) {
if (targets.isEmpty()) {
return null;
}

if (targets.size() == 1) {
return (LivingEntity)targets.get(0);
}

Comparator var10001;
switch (this.sort.getIndex()) {
case 0 -> var10001 = Comparator.comparingDouble(this::getDistance);
case 1 -> var10001 = Comparator.comparingDouble(LivingEntity::getHealth);
case 2 -> var10001 = Comparator.comparingDouble(this::getDegree);
default -> var10001 = null;
}

return (LivingEntity)Collections.min(targets, var10001);
}

entity = (Entity)var2.next();
} while(!(entity instanceof LivingEntity));

living = (LivingEntity)entity;
} while(!this.isValid(living));
} while(!(this.getDistance(living) <= (double)(this.range.getValue().floatValue() + (this.mode.is("Обычная") ? this.preRange.getValue().floatValue() : 0.0F))));
} while(this.ignore.get(0) && Managment.FRIEND_MANAGER.isFriend(living.getName().getString()));
} while(this.ignore.get(1) && living.isInvisible());
} while((double)living.getHealth() < 0.01);
} while(this.ignore.get(2) && living instanceof PlayerEntity && living.getTotalArmorValue() == 0);
} while(this.ignore.get(3) && living instanceof PlayerEntity && !living.getUniqueID().equals(PlayerEntity.getOfflineUUID(living.getName().getString())));

targets.add(living);
}
}

private boolean isValid(LivingEntity entity) {
if (!(entity instanceof ArmorStandEntity) && entity != mc.player) {
if (entity instanceof PlayerEntity) {
return this.targets.get(0);
} else if (!(entity instanceof AnimalEntity) && !(entity instanceof VillagerEntity) && !(entity instanceof WaterMobEntity)) {
return !(entity instanceof MonsterEntity) && !(entity instanceof SlimeEntity) ? true : this.targets.get(2);
} else {
return this.targets.get(1);
}
} else {
return false;
}
}

private void updateClientRotation(float yaw, float pitch) {
mc.player.rotationYawHead = yaw;
mc.player.renderYawOffset = yaw;
mc.player.rotationPitchHead = pitch;
}

private void reset() {
this.rotYaw = mc.player.rotationYaw;
this.rotPitch = mc.player.rotationPitch;
target = null;
}

private void attackEntity(LivingEntity entity) {
mc.playerController.attackEntity(mc.player, entity);
mc.player.swingArm(Hand.MAIN_HAND);
}

private boolean isInHitBox(LivingEntity me, LivingEntity to) {
double wHalf = (double)(to.getWidth() / 2.0F);
double yExpand = MathHelper.clamp(me.getPosYEye() - to.getPosY(), 0.0, (double)to.getHeight());
double xExpand = MathHelper.clamp(mc.player.getPosX() - to.getPosX(), -wHalf, wHalf);
double zExpand = MathHelper.clamp(mc.player.getPosZ() - to.getPosZ(), -wHalf, wHalf);
return (new Vector3d(to.getPosX() - me.getPosX() + xExpand, to.getPosY() - me.getPosYEye() + yExpand, to.getPosZ() - me.getPosZ() + zExpand)).length() == 0.0;
}

private Vector3d getVector3d(LivingEntity me, LivingEntity to) {
double wHalf = (double)(to.getWidth() / 2.0F);
double yExpand = MathHelper.clamp(me.getPosYEye() - to.getPosY(), 0.0, (double)(to.getHeight() * (mc.player.getDistance(to) / this.range.getValue().floatValue())));
double xExpand = MathHelper.clamp(mc.player.getPosX() - to.getPosX(), -wHalf, wHalf);
double zExpand = MathHelper.clamp(mc.player.getPosZ() - to.getPosZ(), -wHalf, wHalf);
return new Vector3d(to.getPosX() - me.getPosX() + xExpand, to.getPosY() - me.getPosYEye() + yExpand, to.getPosZ() - me.getPosZ() + zExpand);
}

private double getDistance(LivingEntity entity) {
return this.getVector3d(mc.player, entity).length();
}

private double getDegree(LivingEntity entity) {
Vector3d vec = this.getVector3d(mc.player, entity);
double yaw = MathHelper.wrapDegrees(Math.toDegrees(Math.atan2(vec.z, vec.x)) - 90.0);
double delta = MathHelper.wrapDegrees(yaw - (double)mc.player.rotationYaw);
if (Math.abs(delta) > 180.0) {
delta -= Math.signum(delta) * 360.0;
}

return Math.abs(delta);
}

private boolean isLookingAtMe(LivingEntity target) {
double x = target.getPosX() - mc.player.getPosX();
double z = target.getPosZ() - mc.player.getPosZ();
float entityYaw = MathHelper.wrapDegrees(target.rotationYaw);
double yaw = Math.toDegrees(Math.atan2(z, x)) + 90.0;
return Math.abs(MathHelper.wrapDegrees(yaw - (double)entityYaw)) <= 90.0;
}

private void drawCircle(LivingEntity target, EventRender e) {
EntityRendererManager rm = mc.getRenderManager();
double x = target.lastTickPosX + (target.getPosX() - target.lastTickPosX) * (double)e.partialTicks - rm.info.getProjectedView().getX();
double y = target.lastTickPosY + (target.getPosY() - target.lastTickPosY) * (double)e.partialTicks - rm.info.getProjectedView().getY();
double z = target.lastTickPosZ + (target.getPosZ() - target.lastTickPosZ) * (double)e.partialTicks - rm.info.getProjectedView().getZ();
float height = target.getHeight();
double duration = 2000.0;
double elapsed = (double)System.currentTimeMillis() % duration;
boolean side = elapsed > duration / 2.0;
double progress = elapsed / (duration / 2.0);
if (side) {
--progress;
} else {
progress = 1.0 - progress;
}

progress = progress < 0.5 ? 2.0 * progress * progress : 1.0 - Math.pow(-2.0 * progress + 2.0, 2.0) / 2.0;
double eased = (double)(height / 2.0F) * (progress > 0.5 ? 1.0 - progress : progress) * (double)(side ? -1 : 1);
RenderSystem.pushMatrix();
GL11.glDepthMask(false);
GL11.glEnable(2848);
GL11.glHint(3154, 4354);
RenderSystem.disableTexture();
RenderSystem.enableBlend();
RenderSystem.disableAlphaTest();
RenderSystem.shadeModel(7425);
RenderSystem.disableCull();
RenderSystem.lineWidth(1.5F);
RenderSystem.color4f(-1.0F, -1.0F, -1.0F, -1.0F);
buffer.begin(8, DefaultVertexFormats.POSITION_COLOR);
float[] colors = null;

int i;
for(i = 0; i <= 360; ++i) {
colors = IntColor.rgb(Managment.STYLE_MANAGER.getCurrentStyle().getColor(i));
buffer.pos(x + Math.cos(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8, y + (double)height * progress, z + Math.sin(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8).color(colors[0], colors[1], colors[2], 0.5F).endVertex();
buffer.pos(x + Math.cos(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8, y + (double)height * progress + eased, z + Math.sin(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8).color(colors[0], colors[1], colors[2], 0.0F).endVertex();
}

buffer.finishDrawing();
WorldVertexBufferUploader.draw(buffer);
RenderSystem.color4f(-1.0F, -1.0F, -1.0F, -1.0F);
buffer.begin(2, DefaultVertexFormats.POSITION_COLOR);

for(i = 0; i <= 360; ++i) {
buffer.pos(x + Math.cos(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8, y + (double)height * progress, z + Math.sin(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8).color(colors[0], colors[1], colors[2], 0.5F).endVertex();
}

buffer.finishDrawing();
WorldVertexBufferUploader.draw(buffer);
RenderSystem.enableCull();
RenderSystem.disableBlend();
RenderSystem.enableTexture();
RenderSystem.enableAlphaTest();
GL11.glDepthMask(true);
GL11.glDisable(2848);
GL11.glHint(3154, 4354);
RenderSystem.shadeModel(7424);
RenderSystem.popMatrix();
}

protected void onDisable() {
super.onDisable();
this.reset();
}

protected void onEnable() {
super.onEnable();
this.reset();
}

public static LivingEntity getTarget() {
return target;
}

public float getRotYaw() {
return this.rotYaw;
}

public float getRotPitch() {
return this.rotPitch;
}
}

//5
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.movement;

import java.util.Iterator;
import net.minecraft.entity.Entity;
import net.minecraft.entity.item.ItemEntity;
import net.minecraft.item.ElytraItem;
import net.minecraft.item.SkullItem;
import net.minecraft.item.SpawnEggItem;
import net.minecraft.util.math.MathHelper;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;

@FunctionAnnotation(
name = "AutoPilot",
type = Type.Movement
)
public class AutoPilot extends Function {
public AutoPilot() {
}

public void onEvent(Event event) {
boolean skullItemNoNull = false;
boolean eggItemNoNull = false;
boolean elytraItemNoNull = false;
Iterator var5;
Entity entity;
if (event instanceof EventUpdate) {
var5 = mc.world.getAllEntities().iterator();

while(var5.hasNext()) {
entity = (Entity)var5.next();
if (entity instanceof ItemEntity) {
if (((ItemEntity)entity).getItem().getItem() instanceof SkullItem) {
skullItemNoNull = true;
}

if (((ItemEntity)entity).getItem().getItem() instanceof ElytraItem) {
elytraItemNoNull = true;
}

if (((ItemEntity)entity).getItem().getItem() instanceof SpawnEggItem) {
eggItemNoNull = true;
}
}
}
}

if (event instanceof EventUpdate) {
var5 = mc.world.getAllEntities().iterator();

while(var5.hasNext()) {
entity = (Entity)var5.next();
if (entity instanceof ItemEntity) {
if (((ItemEntity)entity).getItem().getItem() instanceof SkullItem) {
mc.player.rotationYaw = this.rotations(entity)[0];
mc.player.rotationPitch = this.rotations(entity)[1];
break;
}

if (((ItemEntity)entity).getItem().getItem() instanceof ElytraItem && !skullItemNoNull) {
mc.player.rotationYaw = this.rotations(entity)[0];
mc.player.rotationPitch = this.rotations(entity)[1];
break;
}

if (((ItemEntity)entity).getItem().getItem() instanceof SpawnEggItem && !elytraItemNoNull && !skullItemNoNull) {
mc.player.rotationYaw = this.rotations(entity)[0];
mc.player.rotationPitch = this.rotations(entity)[1];
break;
}
}
}

skullItemNoNull = true;
elytraItemNoNull = true;
eggItemNoNull = true;
}

}

public float[] rotations(Entity entity) {
double x = entity.getPosX() - mc.player.getPosX();
double y = entity.getPosY() - mc.player.getPosY() - 1.5;
double z = entity.getPosZ() - mc.player.getPosZ();
double u = (double)MathHelper.sqrt(x * x + z * z);
float u2 = (float)(MathHelper.atan2(z, x) * 57.29577951308232 - 90.0);
float u3 = (float)(-MathHelper.atan2(y, u) * 57.29577951308232);
return new float[]{u2, u3};
}
}
а ты нам чо?
 
Забаненный
Статус
Оффлайн
Регистрация
5 Май 2024
Сообщения
44
Реакции[?]
0
Поинты[?]
0
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Последнее редактирование:
Забаненный
Статус
Оффлайн
Регистрация
5 Май 2024
Сообщения
44
Реакции[?]
0
Поинты[?]
0
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Начинающий
Статус
Онлайн
Регистрация
26 Фев 2024
Сообщения
412
Реакции[?]
0
Поинты[?]
0
//1
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package im.expensive.modules.impl.movement;

import net.minecraft.inventory.container.ClickType;
import net.minecraft.item.ItemStack;
import net.minecraft.item.Items;
import net.minecraft.network.play.client.CEntityActionPacket;
import net.minecraft.network.play.client.CEntityActionPacket.Action;
import net.minecraft.network.play.server.SEntityMetadataPacket;
import net.minecraft.util.Hand;
import net.minecraft.util.text.TextFormatting;
import im.expensive.events.Event;
import im.expensive.events.impl.packet.EventPacket;
import im.expensive.events.impl.player.EventMotion;
import im.expensive.events.impl.player.EventUpdate;
import im.expensive.modules.Function;
import im.expensive.modules.FunctionAnnotation;
import im.expensive.modules.Type;
import im.expensive.modules.settings.Setting;
import im.expensive.modules.settings.imp.BooleanOption;
import im.expensive.modules.settings.imp.SliderSetting;
import im.expensive.util.ClientUtil;
import im.expensive.util.misc.TimerUtil;
import im.expensive.util.movement.MoveUtil;
import im.expensive.util.world.InventoryUtil;

@FunctionAnnotation(
name = "CatStrafe",
type = Type.Movement
)
public class CatStrafe extends Function {
private final TimerUtil timerUtil = new TimerUtil();
int oldItem = -1;
private final SliderSetting speedBoost = new SliderSetting("Скорость", 0.3F, 0.0F, 0.8F, 1.0E-4F);
private final BooleanOption autoJump = new BooleanOption("Авто прыжок", false);
private final BooleanOption safeMode = new BooleanOption("Безопасный режим", false);
boolean test1 = false;

public CatStrafe() {
this.addSettings(new Setting[]{this.speedBoost, this.safeMode, this.autoJump});
}

protected void onEnable() {
super.onEnable();
}

public void onEvent(Event event) {
if (event instanceof EventUpdate) {
if (mc.player.collidedHorizontally && this.safeMode.get()) {
ClientUtil.sendMesage(TextFormatting.RED + "Вы столкнулись с блоком, перезапустите функцию!");
this.toggle();
return;
}

if (InventoryUtil.getItemSlot(Items.FIREWORK_ROCKET) == -1 || mc.player.collidedHorizontally || !InventoryUtil.doesHotbarHaveItem(Items.ELYTRA)) {
return;
}

if (this.autoJump.get() && !mc.gameSettings.keyBindJump.isKeyDown() && mc.player.isOnGround()) {
mc.gameSettings.keyBindJump.setPressed(true);
}

if (mc.player.getActiveHand() == Hand.MAIN_HAND) {
mc.playerController.onStoppedUsingItem(mc.player);
}
}

if (event instanceof EventMotion eventMotion) {
eventMotion.setPitch(15.0F);
mc.player.rotationPitchHead = 15.0F;
}

if (event instanceof EventUpdate) {
mc.gameSettings.keyBindBack.setPressed(false);
mc.gameSettings.keyBindLeft.setPressed(false);
mc.gameSettings.keyBindRight.setPressed(false);
boolean test = false;
if ((mc.player.isOnGround() || mc.player.fallDistance != 0.0F && mc.gameSettings.keyBindJump.isKeyDown()) && this.timerUtil.hasTimeElapsed(600L)) {
test = true;
}

if (mc.player.isOnGround() && test) {
mc.gameSettings.keyBindForward.setPressed(false);
return;
}

if (mc.player.fallDistance == 0.0F && !mc.player.isOnGround()) {
test = false;
}

for(int i = 0; i < 9; ++i) {
if (mc.player.inventory.getStackInSlot(i).getItem() == Items.ELYTRA && !mc.player.isOnGround() && !mc.player.isInWater() && !mc.player.isInLava()) {
float speed;
if (InventoryUtil.doesHotbarHaveItem(Items.FIREWORK_ROCKET) && this.timerUtil.hasTimeElapsed(300L)) {
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_FALL_FLYING));
speed = 0.9F + this.speedBoost.getValue().floatValue();
MoveUtil.setMotion((double)speed);
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
if (this.timerUtil.hasTimeElapsed(300L)) {
InventoryUtil.inventorySwapClick(Items.FIREWORK_ROCKET, false);
this.timerUtil.reset();
}
}

if (!InventoryUtil.doesHotbarHaveItem(Items.FIREWORK_ROCKET) && this.timerUtil.hasTimeElapsed(300L)) {
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_FALL_FLYING));
speed = 0.9F + this.speedBoost.getValue().floatValue();
MoveUtil.setMotion((double)speed);
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
if (this.timerUtil.hasTimeElapsed(300L)) {
InventoryUtil.inventorySwapClick(Items.FIREWORK_ROCKET, false);
this.timerUtil.reset();
}
}
}
}
}

if (event instanceof EventPacket e) {
if (e.getPacket() instanceof SEntityMetadataPacket && ((SEntityMetadataPacket)e.getPacket()).getEntityId() == mc.player.getEntityId()) {
e.setCancel(true);
}
}

}

public void onDisable() {
super.onDisable();
if (this.oldItem != -1) {
if (((ItemStack)mc.player.inventory.armorInventory.get(2)).getItem() == Items.ELYTRA) {
mc.playerController.windowClick(0, this.oldItem < 9 ? this.oldItem + 36 : this.oldItem, 38, ClickType.SWAP, mc.player);
}

this.oldItem = -1;
}

}
}
//2
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.movement;

import net.minecraft.block.Blocks;
import net.minecraft.inventory.container.ClickType;
import net.minecraft.item.Items;
import net.minecraft.item.UseAction;
import net.minecraft.network.play.client.CEntityActionPacket;
import net.minecraft.network.play.client.CEntityActionPacket.Action;
import net.minecraft.util.Hand;
import net.minecraft.util.math.BlockPos;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;
import wtf.expensive.modules.settings.Setting;
import wtf.expensive.modules.settings.imp.BooleanOption;
import wtf.expensive.modules.settings.imp.SliderSetting;
import wtf.expensive.util.misc.TimerUtil;
import wtf.expensive.util.world.InventoryUtil;

@FunctionAnnotation(
name = "CatFly",
type = Type.Movement
)
public class CatFly extends Function {
private final TimerUtil timerUtil = new TimerUtil();
private final TimerUtil timerUtil1 = new TimerUtil();
private final SliderSetting timerStartFireWork = new SliderSetting("Таймер фейерверка", 400.0F, 50.0F, 1500.0F, 1.0F);
private final BooleanOption onlyGrimBypass = new BooleanOption("Обходить только грим", false);
private final BooleanOption noFireWorkifEat = new BooleanOption("Отсутствие еды в правой руке", false);

public CatFly() {
this.addSettings(new Setting[]{this.timerStartFireWork, this.onlyGrimBypass, this.noFireWorkifEat});
}

public void onEvent(Event event) {
if (InventoryUtil.getItemSlot(Items.FIREWORK_ROCKET) != -1) {
if (event instanceof EventUpdate) {
int timeSwap = 200;
if (this.onlyGrimBypass.get()) {
timeSwap = 0;
}

boolean startFireWork = true;
if (this.noFireWorkifEat.get() && mc.player.getActiveHand() == Hand.MAIN_HAND && mc.player.getHeldItemMainhand().getUseAction() == UseAction.EAT) {
startFireWork = false;
}

for(int i = 0; i < 9; ++i) {
if (mc.player.inventory.getStackInSlot(i).getItem() == Items.ELYTRA && mc.world.getBlockState(new BlockPos(mc.player.getPosX(), mc.player.getPosY() - 0.01, mc.player.getPosZ())).getBlock() == Blocks.AIR && !mc.player.isOnGround() && !mc.player.isInWater() && !mc.player.isInLava() && !mc.player.isElytraFlying()) {
if (this.timerUtil1.hasTimeElapsed((long)timeSwap)) {
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
mc.player.startFallFlying();
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_FALL_FLYING));
mc.playerController.windowClick(0, 6, i, ClickType.SWAP, mc.player);
this.timerUtil1.reset();
}

if (this.timerUtil.hasTimeElapsed((long)this.timerStartFireWork.getValue().intValue()) && mc.player.isElytraFlying()) {
if (startFireWork) {
InventoryUtil.inventorySwapClick(Items.FIREWORK_ROCKET, false);
}

this.timerUtil.reset();
}
}
}
}

}
}

public void onDisable() {
super.onDisable();
}
}

//3
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.movement;

import net.minecraft.item.UseAction;
import net.minecraft.network.IPacket;
import net.minecraft.network.play.client.CHeldItemChangePacket;
import net.minecraft.network.play.client.CPlayerTryUseItemPacket;
import net.minecraft.network.play.server.SEntityVelocityPacket;
import net.minecraft.network.play.server.SHeldItemChangePacket;
import net.minecraft.network.play.server.SPlayerPositionLookPacket;
import net.minecraft.util.Hand;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.packet.EventPacket;
import wtf.expensive.events.impl.player.EventDamage;
import wtf.expensive.events.impl.player.EventNoSlow;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;
import wtf.expensive.modules.settings.Setting;
import wtf.expensive.modules.settings.imp.BooleanOption;
import wtf.expensive.modules.settings.imp.ModeSetting;
import wtf.expensive.util.misc.DamageUtil;
import wtf.expensive.util.misc.TimerUtil;
import wtf.expensive.util.movement.MoveUtil;

@FunctionAnnotation(
name = "NoSlow",
type = Type.Movement
)
public class NoSlowFunction extends Function {
public ModeSetting mode = new ModeSetting("Мод", "Really World", new String[]{"Vanilla", "Really World", "GrimAC"});
private DamageUtil damageUtil = new DamageUtil();
public TimerUtil timerUtil = new TimerUtil();
public BooleanOption matrix = new BooleanOption("Фикс свапа", true);
public BooleanOption matrix1 = (new BooleanOption("Работать только в воде", true)).setVisible(() -> {
return this.mode.is("Really World");
});
public BooleanOption matrix2 = (new BooleanOption("Работать только от урона", true)).setVisible(() -> {
return this.mode.is("Really World");
});
public BooleanOption matrix3 = (new BooleanOption("Выключить работать от урона", true)).setVisible(() -> {
return this.mode.is("Really World");
});
boolean restart = false;
boolean restart1 = false;
boolean test = true;

public NoSlowFunction() {
this.addSettings(new Setting[]{this.mode, this.matrix, this.matrix1, this.matrix2, this.matrix3});
}

public void onEvent(Event event) {
if (!mc.player.isElytraFlying()) {
EventNoSlow eventNoSlow;
if (event instanceof EventNoSlow) {
eventNoSlow = (EventNoSlow)event;
this.handleEventUpdate(eventNoSlow);
} else if (event instanceof EventDamage) {
EventDamage damage = (EventDamage)event;
this.damageUtil.processDamage(damage);
} else if (event instanceof EventPacket) {
EventPacket eventPacket = (EventPacket)event;
if (eventPacket.isReceivePacket()) {
this.damageUtil.onPacketEvent(eventPacket);
}
}

EventPacket e;
IPacket var8;
if (this.matrix.get() && event instanceof EventPacket) {
e = (EventPacket)event;
if (e.isReceivePacket()) {
var8 = e.getPacket();
if (var8 instanceof SHeldItemChangePacket) {
SHeldItemChangePacket packetHeldItemChange = (SHeldItemChangePacket)var8;
if (this.timerUtil.hasTimeElapsed(100L)) {
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem % 8 + 1));
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
this.timerUtil.reset();
}

event.setCancel(true);
}
}
}

if (this.mode.is("Really World")) {
if (this.matrix1.get() && !mc.player.isInWater()) {
return;
}

if (event instanceof EventUpdate) {
if (!this.restart) {
this.restart1 = true;
}

if (this.restart) {
if (this.restart1) {
this.timerUtil.reset();
this.restart1 = false;
}

if (this.timerUtil.hasTimeElapsed(1650L, true)) {
this.restart = false;
}
}
}

if (event instanceof EventPacket) {
e = (EventPacket)event;
if (!this.test && this.timerUtil.hasTimeElapsed(10L)) {
this.test = true;
this.timerUtil.reset();
}

var8 = e.getPacket();
if (var8 instanceof SPlayerPositionLookPacket) {
SPlayerPositionLookPacket p = (SPlayerPositionLookPacket)var8;
this.test = false;
this.timerUtil.reset();
}

if (e.getPacket() instanceof SEntityVelocityPacket && this.test && ((SEntityVelocityPacket)e.getPacket()).getEntityID() == mc.player.getEntityId() && !mc.player.isElytraFlying()) {
if (this.matrix3.get()) {
return;
}

this.restart = false;
this.restart1 = false;
this.restart = true;
this.restart1 = true;
}
}

if (event instanceof EventNoSlow) {
eventNoSlow = (EventNoSlow)event;
if ((mc.player.isInWater() || this.restart) && mc.player.getActiveHand() == Hand.MAIN_HAND && mc.player.getHeldItemOffhand().getUseAction() == UseAction.NONE) {
mc.player.connection.sendPacket(new CPlayerTryUseItemPacket(Hand.OFF_HAND));
eventNoSlow.setCancel(true);
}

if (mc.player.getActiveHand() == Hand.OFF_HAND) {
if (this.matrix2.get() && !mc.player.isInWater() && !this.restart) {
return;
}

mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem % 8 + 1));
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
eventNoSlow.setCancel(true);
}
}
}

}
}

private void handleEventUpdate(EventNoSlow eventNoSlow) {
if (mc.player.isHandActive()) {
switch (this.mode.get()) {
case "Vanilla" -> eventNoSlow.setCancel(true);
case "GrimAC" -> this.handleGrimACMode(eventNoSlow);
}
}

}

private void handleGrimACMode(EventNoSlow noSlow) {
if ((mc.player.getHeldItemOffhand().getUseAction() != UseAction.BLOCK || mc.player.getActiveHand() != Hand.MAIN_HAND) && (mc.player.getHeldItemOffhand().getUseAction() != UseAction.EAT || mc.player.getActiveHand() != Hand.MAIN_HAND)) {
if (mc.player.getActiveHand() == Hand.MAIN_HAND) {
mc.player.connection.sendPacket(new CPlayerTryUseItemPacket(Hand.OFF_HAND));
noSlow.setCancel(true);
} else {
noSlow.setCancel(true);
this.sendItemChangePacket();
}
}
}

private void sendItemChangePacket() {
if (MoveUtil.isMoving()) {
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem % 8 + 1));
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
}

}

protected void onEnable() {
super.onEnable();
this.restart1 = false;
this.restart = false;
}
}
//4
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.combat;

import com.mojang.blaze3d.systems.RenderSystem;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.Iterator;
import java.util.List;
import java.util.concurrent.ThreadLocalRandom;
import net.minecraft.client.renderer.WorldVertexBufferUploader;
import net.minecraft.client.renderer.entity.EntityRendererManager;
import net.minecraft.client.renderer.vertex.DefaultVertexFormats;
import net.minecraft.entity.Entity;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.item.ArmorStandEntity;
import net.minecraft.entity.merchant.villager.VillagerEntity;
import net.minecraft.entity.monster.MonsterEntity;
import net.minecraft.entity.monster.SlimeEntity;
import net.minecraft.entity.passive.AnimalEntity;
import net.minecraft.entity.passive.WaterMobEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.network.play.client.CEntityActionPacket;
import net.minecraft.network.play.client.CHeldItemChangePacket;
import net.minecraft.network.play.client.CEntityActionPacket.Action;
import net.minecraft.potion.Effects;
import net.minecraft.tags.FluidTags;
import net.minecraft.util.Hand;
import net.minecraft.util.math.MathHelper;
import net.minecraft.util.math.vector.Vector3d;
import org.lwjgl.opengl.GL11;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.player.EventInput;
import wtf.expensive.events.impl.player.EventInteractEntity;
import wtf.expensive.events.impl.player.EventMotion;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.events.impl.player.EventWorldChange;
import wtf.expensive.events.impl.render.EventRender;
import wtf.expensive.managment.Managment;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;
import wtf.expensive.modules.settings.Setting;
import wtf.expensive.modules.settings.imp.BooleanOption;
import wtf.expensive.modules.settings.imp.ModeSetting;
import wtf.expensive.modules.settings.imp.MultiBoxSetting;
import wtf.expensive.modules.settings.imp.SliderSetting;
import wtf.expensive.util.ClientUtil;
import wtf.expensive.util.math.GCDUtil;
import wtf.expensive.util.math.RayTraceUtil;
import wtf.expensive.util.movement.MoveUtil;
import wtf.expensive.util.render.RenderUtil.IntColor;
import wtf.expensive.util.world.InventoryUtil;

@FunctionAnnotation(
name = "AuraNew",
type = Type.Combat
)
public class AuraNew extends Function {
private final ModeSetting mode = new ModeSetting("Режим ротации", "Снапы", new String[]{"Обычная", "Снапы"});
private final SliderSetting range = new SliderSetting("Дистанция", 3.0F, 3.0F, 6.0F, 0.05F);
private final SliderSetting preRange = (new SliderSetting("Дистанция ротации", 0.5F, 0.0F, 3.0F, 0.05F)).setVisible(() -> {
return this.mode.is("Обычная");
});
private final MultiBoxSetting targets = new MultiBoxSetting("Цели", new BooleanOption[]{new BooleanOption("Игроки", true), new BooleanOption("Животные", false), new BooleanOption("Монстры", false)});
private final MultiBoxSetting ignore = new MultiBoxSetting("Игнорировать", new BooleanOption[]{new BooleanOption("Друзей", true), new BooleanOption("Невидимых", false), new BooleanOption("Голых", false), new BooleanOption("Ботов", true)});
private final ModeSetting sort = new ModeSetting("Сортировать", "По дистанции", new String[]{"По дистанции", "По здоровью", "По полю зрения"});
public final MultiBoxSetting settings = new MultiBoxSetting("Настройки", new BooleanOption[]{new BooleanOption("Только критами", true), new BooleanOption("Коррекция движения", true), new BooleanOption("Не бить при использовании", false), new BooleanOption("Отжимать щит", true), new BooleanOption("Ломать щит", true)});
private final BooleanOption space = (new BooleanOption("Криты только с пробелом", false)).setVisible(() -> {
return this.settings.get(0);
});
private final BooleanOption silent = (new BooleanOption("Сайлент коррекция", true)).setVisible(() -> {
return this.settings.get(1);
});
private long cpsLimit = 0L;
public static LivingEntity target;
float rotYaw;
float rotPitch;
int ticks;

public AuraNew() {
this.addSettings(new Setting[]{this.range, this.preRange, this.mode, this.targets, this.ignore, this.sort, this.settings, this.space, this.silent});
}

public void onEvent(Event event) {
if (mc.player != null && mc.world != null) {
if (event instanceof EventInteractEntity) {
EventInteractEntity entity = (EventInteractEntity)event;
if (target != null) {
entity.setCancel(true);
}
}

if (event instanceof EventInput) {
EventInput e = (EventInput)event;
if (this.settings.get(1) && this.silent.get()) {
MoveUtil.fixMovement(e, this.rotYaw);
}
}

if (event instanceof EventUpdate) {
target = this.findTarget();
if (target == null) {
this.reset();
return;
}

switch (this.mode.getIndex()) {
case 0:
this.updateRotation(0.5F);
if (this.canAttack() && RayTraceUtil.getMouseOver(target, this.rotYaw, this.rotPitch, (double)this.range.getValue().floatValue()) == target) {
this.updateAttack(target);
}
break;
case 1:
if (this.canAttack()) {
this.updateAttack(target);
this.ticks = 3;
}

if (this.ticks > 0) {
this.updateRotation(1.0F);
--this.ticks;
} else {
this.rotYaw = mc.player.rotationYaw;
this.rotPitch = mc.player.rotationPitch;
}
}
}

if (event instanceof EventMotion) {
EventMotion e = (EventMotion)event;
if (target == null) {
return;
}

e.setYaw(this.rotYaw);
e.setPitch(this.rotPitch);
this.updateClientRotation(this.rotYaw, this.rotPitch);
}

if (event instanceof EventWorldChange) {
this.reset();
}

if (event instanceof EventRender) {
EventRender e = (EventRender)event;
if (e.isRender3D() && target != null) {
}
}

}
}

private void updateRotation(float speed) {
if (!this.isInHitBox(mc.player, target)) {
Vector3d vec3d = this.getVector3d(mc.player, target);
float rawYaw = (float)MathHelper.wrapDegrees(Math.toDegrees(Math.atan2(vec3d.z, vec3d.x)) - 90.0);
float rawPitch = (float)MathHelper.wrapDegrees(Math.toDegrees(-Math.atan2(vec3d.y, Math.hypot(vec3d.x, vec3d.z))));
float yawDelta = MathHelper.wrapDegrees(rawYaw - this.rotYaw);
float pitchDelta = MathHelper.wrapDegrees(rawPitch - this.rotPitch);
if (Math.abs(yawDelta) > 180.0F) {
yawDelta -= Math.signum(yawDelta) * 360.0F;
}

float additionYaw = MathHelper.clamp(yawDelta, -180.0F * speed, 180.0F * speed);
float additionPitch = MathHelper.clamp(pitchDelta, -90.0F * speed, 90.0F * speed);
float yaw = this.rotYaw + additionYaw + ThreadLocalRandom.current().nextFloat(-1.0F, 1.0F);
float pitch = this.rotPitch + additionPitch + ThreadLocalRandom.current().nextFloat(-1.0F, 1.0F);
this.rotYaw = GCDUtil.getSensitivity(yaw);
this.rotPitch = GCDUtil.getSensitivity(MathHelper.clamp(pitch, -89.0F, 89.0F));
}
}

private void updateAttack(LivingEntity target) {
if (mc.player.isHandActive()) {
if (this.settings.get(3) && mc.player.isActiveItemStackBlocking()) {
mc.playerController.onStoppedUsingItem(mc.player);
} else if (this.settings.get(2)) {
return;
}
}

boolean sprint = false;
if (this.settings.get(0) && CEntityActionPacket.lastUpdatedSprint) {
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.STOP_SPRINTING));
if (!mc.player.isInWater()) {
mc.player.setSprinting(false);
}

sprint = true;
}

this.cpsLimit = System.currentTimeMillis() + 550L;
this.attackEntity(target);
if (this.settings.get(4) && target.isBlocking()) {
int slot = InventoryUtil.getAxe(true);
if (slot == -1) {
return;
}

mc.player.connection.sendPacket(new CHeldItemChangePacket(slot));
this.attackEntity(target);
mc.player.connection.sendPacket(new CHeldItemChangePacket(mc.player.inventory.currentItem));
ClientUtil.sendMesage("БРЯК: " + mc.player.ticksExisted);
}

if (sprint) {
mc.player.connection.sendPacket(new CEntityActionPacket(mc.player, Action.START_SPRINTING));
}

}

private boolean canAttack() {
if (this.cpsLimit < System.currentTimeMillis() && !Managment.FUNCTION_MANAGER.autoPotionFunction.isActivePotion && !(this.getDistance(target) >= (double)this.range.getValue().floatValue()) && !(mc.player.getCooledAttackStrength(1.0F) <= 0.93F)) {
if ((!mc.player.isInWater() || !mc.player.areEyesInFluid(FluidTags.WATER)) && !mc.player.isInLava() && !mc.player.isOnLadder() && !mc.player.isRidingHorse() && !mc.player.abilities.isFlying && !mc.player.isElytraFlying() && !mc.player.isPotionActive(Effects.LEVITATION) && !mc.player.isPotionActive(Effects.SLOW_FALLING) && this.settings.get(0)) {
return this.space.get() && !mc.player.movementInput.jump || mc.player.fallDistance > 0.0F && !mc.player.isOnGround();
} else {
return true;
}
} else {
return false;
}
}

private LivingEntity findTarget() {
List<LivingEntity> targets = new ArrayList();
Iterator var2 = mc.world.getAllEntities().iterator();

while(true) {
LivingEntity living;
do {
do {
do {
do {
do {
do {
do {
Entity entity;
do {
if (!var2.hasNext()) {
if (targets.isEmpty()) {
return null;
}

if (targets.size() == 1) {
return (LivingEntity)targets.get(0);
}

Comparator var10001;
switch (this.sort.getIndex()) {
case 0 -> var10001 = Comparator.comparingDouble(this::getDistance);
case 1 -> var10001 = Comparator.comparingDouble(LivingEntity::getHealth);
case 2 -> var10001 = Comparator.comparingDouble(this::getDegree);
default -> var10001 = null;
}

return (LivingEntity)Collections.min(targets, var10001);
}

entity = (Entity)var2.next();
} while(!(entity instanceof LivingEntity));

living = (LivingEntity)entity;
} while(!this.isValid(living));
} while(!(this.getDistance(living) <= (double)(this.range.getValue().floatValue() + (this.mode.is("Обычная") ? this.preRange.getValue().floatValue() : 0.0F))));
} while(this.ignore.get(0) && Managment.FRIEND_MANAGER.isFriend(living.getName().getString()));
} while(this.ignore.get(1) && living.isInvisible());
} while((double)living.getHealth() < 0.01);
} while(this.ignore.get(2) && living instanceof PlayerEntity && living.getTotalArmorValue() == 0);
} while(this.ignore.get(3) && living instanceof PlayerEntity && !living.getUniqueID().equals(PlayerEntity.getOfflineUUID(living.getName().getString())));

targets.add(living);
}
}

private boolean isValid(LivingEntity entity) {
if (!(entity instanceof ArmorStandEntity) && entity != mc.player) {
if (entity instanceof PlayerEntity) {
return this.targets.get(0);
} else if (!(entity instanceof AnimalEntity) && !(entity instanceof VillagerEntity) && !(entity instanceof WaterMobEntity)) {
return !(entity instanceof MonsterEntity) && !(entity instanceof SlimeEntity) ? true : this.targets.get(2);
} else {
return this.targets.get(1);
}
} else {
return false;
}
}

private void updateClientRotation(float yaw, float pitch) {
mc.player.rotationYawHead = yaw;
mc.player.renderYawOffset = yaw;
mc.player.rotationPitchHead = pitch;
}

private void reset() {
this.rotYaw = mc.player.rotationYaw;
this.rotPitch = mc.player.rotationPitch;
target = null;
}

private void attackEntity(LivingEntity entity) {
mc.playerController.attackEntity(mc.player, entity);
mc.player.swingArm(Hand.MAIN_HAND);
}

private boolean isInHitBox(LivingEntity me, LivingEntity to) {
double wHalf = (double)(to.getWidth() / 2.0F);
double yExpand = MathHelper.clamp(me.getPosYEye() - to.getPosY(), 0.0, (double)to.getHeight());
double xExpand = MathHelper.clamp(mc.player.getPosX() - to.getPosX(), -wHalf, wHalf);
double zExpand = MathHelper.clamp(mc.player.getPosZ() - to.getPosZ(), -wHalf, wHalf);
return (new Vector3d(to.getPosX() - me.getPosX() + xExpand, to.getPosY() - me.getPosYEye() + yExpand, to.getPosZ() - me.getPosZ() + zExpand)).length() == 0.0;
}

private Vector3d getVector3d(LivingEntity me, LivingEntity to) {
double wHalf = (double)(to.getWidth() / 2.0F);
double yExpand = MathHelper.clamp(me.getPosYEye() - to.getPosY(), 0.0, (double)(to.getHeight() * (mc.player.getDistance(to) / this.range.getValue().floatValue())));
double xExpand = MathHelper.clamp(mc.player.getPosX() - to.getPosX(), -wHalf, wHalf);
double zExpand = MathHelper.clamp(mc.player.getPosZ() - to.getPosZ(), -wHalf, wHalf);
return new Vector3d(to.getPosX() - me.getPosX() + xExpand, to.getPosY() - me.getPosYEye() + yExpand, to.getPosZ() - me.getPosZ() + zExpand);
}

private double getDistance(LivingEntity entity) {
return this.getVector3d(mc.player, entity).length();
}

private double getDegree(LivingEntity entity) {
Vector3d vec = this.getVector3d(mc.player, entity);
double yaw = MathHelper.wrapDegrees(Math.toDegrees(Math.atan2(vec.z, vec.x)) - 90.0);
double delta = MathHelper.wrapDegrees(yaw - (double)mc.player.rotationYaw);
if (Math.abs(delta) > 180.0) {
delta -= Math.signum(delta) * 360.0;
}

return Math.abs(delta);
}

private boolean isLookingAtMe(LivingEntity target) {
double x = target.getPosX() - mc.player.getPosX();
double z = target.getPosZ() - mc.player.getPosZ();
float entityYaw = MathHelper.wrapDegrees(target.rotationYaw);
double yaw = Math.toDegrees(Math.atan2(z, x)) + 90.0;
return Math.abs(MathHelper.wrapDegrees(yaw - (double)entityYaw)) <= 90.0;
}

private void drawCircle(LivingEntity target, EventRender e) {
EntityRendererManager rm = mc.getRenderManager();
double x = target.lastTickPosX + (target.getPosX() - target.lastTickPosX) * (double)e.partialTicks - rm.info.getProjectedView().getX();
double y = target.lastTickPosY + (target.getPosY() - target.lastTickPosY) * (double)e.partialTicks - rm.info.getProjectedView().getY();
double z = target.lastTickPosZ + (target.getPosZ() - target.lastTickPosZ) * (double)e.partialTicks - rm.info.getProjectedView().getZ();
float height = target.getHeight();
double duration = 2000.0;
double elapsed = (double)System.currentTimeMillis() % duration;
boolean side = elapsed > duration / 2.0;
double progress = elapsed / (duration / 2.0);
if (side) {
--progress;
} else {
progress = 1.0 - progress;
}

progress = progress < 0.5 ? 2.0 * progress * progress : 1.0 - Math.pow(-2.0 * progress + 2.0, 2.0) / 2.0;
double eased = (double)(height / 2.0F) * (progress > 0.5 ? 1.0 - progress : progress) * (double)(side ? -1 : 1);
RenderSystem.pushMatrix();
GL11.glDepthMask(false);
GL11.glEnable(2848);
GL11.glHint(3154, 4354);
RenderSystem.disableTexture();
RenderSystem.enableBlend();
RenderSystem.disableAlphaTest();
RenderSystem.shadeModel(7425);
RenderSystem.disableCull();
RenderSystem.lineWidth(1.5F);
RenderSystem.color4f(-1.0F, -1.0F, -1.0F, -1.0F);
buffer.begin(8, DefaultVertexFormats.POSITION_COLOR);
float[] colors = null;

int i;
for(i = 0; i <= 360; ++i) {
colors = IntColor.rgb(Managment.STYLE_MANAGER.getCurrentStyle().getColor(i));
buffer.pos(x + Math.cos(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8, y + (double)height * progress, z + Math.sin(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8).color(colors[0], colors[1], colors[2], 0.5F).endVertex();
buffer.pos(x + Math.cos(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8, y + (double)height * progress + eased, z + Math.sin(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8).color(colors[0], colors[1], colors[2], 0.0F).endVertex();
}

buffer.finishDrawing();
WorldVertexBufferUploader.draw(buffer);
RenderSystem.color4f(-1.0F, -1.0F, -1.0F, -1.0F);
buffer.begin(2, DefaultVertexFormats.POSITION_COLOR);

for(i = 0; i <= 360; ++i) {
buffer.pos(x + Math.cos(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8, y + (double)height * progress, z + Math.sin(Math.toRadians((double)i)) * (double)target.getWidth() * 0.8).color(colors[0], colors[1], colors[2], 0.5F).endVertex();
}

buffer.finishDrawing();
WorldVertexBufferUploader.draw(buffer);
RenderSystem.enableCull();
RenderSystem.disableBlend();
RenderSystem.enableTexture();
RenderSystem.enableAlphaTest();
GL11.glDepthMask(true);
GL11.glDisable(2848);
GL11.glHint(3154, 4354);
RenderSystem.shadeModel(7424);
RenderSystem.popMatrix();
}

protected void onDisable() {
super.onDisable();
this.reset();
}

protected void onEnable() {
super.onEnable();
this.reset();
}

public static LivingEntity getTarget() {
return target;
}

public float getRotYaw() {
return this.rotYaw;
}

public float getRotPitch() {
return this.rotPitch;
}
}

//5
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package wtf.expensive.modules.impl.movement;

import java.util.Iterator;
import net.minecraft.entity.Entity;
import net.minecraft.entity.item.ItemEntity;
import net.minecraft.item.ElytraItem;
import net.minecraft.item.SkullItem;
import net.minecraft.item.SpawnEggItem;
import net.minecraft.util.math.MathHelper;
import wtf.expensive.events.Event;
import wtf.expensive.events.impl.player.EventUpdate;
import wtf.expensive.modules.Function;
import wtf.expensive.modules.FunctionAnnotation;
import wtf.expensive.modules.Type;

@FunctionAnnotation(
name = "AutoPilot",
type = Type.Movement
)
public class AutoPilot extends Function {
public AutoPilot() {
}

public void onEvent(Event event) {
boolean skullItemNoNull = false;
boolean eggItemNoNull = false;
boolean elytraItemNoNull = false;
Iterator var5;
Entity entity;
if (event instanceof EventUpdate) {
var5 = mc.world.getAllEntities().iterator();

while(var5.hasNext()) {
entity = (Entity)var5.next();
if (entity instanceof ItemEntity) {
if (((ItemEntity)entity).getItem().getItem() instanceof SkullItem) {
skullItemNoNull = true;
}

if (((ItemEntity)entity).getItem().getItem() instanceof ElytraItem) {
elytraItemNoNull = true;
}

if (((ItemEntity)entity).getItem().getItem() instanceof SpawnEggItem) {
eggItemNoNull = true;
}
}
}
}

if (event instanceof EventUpdate) {
var5 = mc.world.getAllEntities().iterator();

while(var5.hasNext()) {
entity = (Entity)var5.next();
if (entity instanceof ItemEntity) {
if (((ItemEntity)entity).getItem().getItem() instanceof SkullItem) {
mc.player.rotationYaw = this.rotations(entity)[0];
mc.player.rotationPitch = this.rotations(entity)[1];
break;
}

if (((ItemEntity)entity).getItem().getItem() instanceof ElytraItem && !skullItemNoNull) {
mc.player.rotationYaw = this.rotations(entity)[0];
mc.player.rotationPitch = this.rotations(entity)[1];
break;
}

if (((ItemEntity)entity).getItem().getItem() instanceof SpawnEggItem && !elytraItemNoNull && !skullItemNoNull) {
mc.player.rotationYaw = this.rotations(entity)[0];
mc.player.rotationPitch = this.rotations(entity)[1];
break;
}
}
}

skullItemNoNull = true;
elytraItemNoNull = true;
eggItemNoNull = true;
}

}

public float[] rotations(Entity entity) {
double x = entity.getPosX() - mc.player.getPosX();
double y = entity.getPosY() - mc.player.getPosY() - 1.5;
double z = entity.getPosZ() - mc.player.getPosZ();
double u = (double)MathHelper.sqrt(x * x + z * z);
float u2 = (float)(MathHelper.atan2(z, x) * 57.29577951308232 - 90.0);
float u3 = (float)(-MathHelper.atan2(y, u) * 57.29577951308232);
return new float[]{u2, u3};
}
}
во первых, ты ебнутый, во вторых ручками, там только импорты, утилки и все почти
 
Сверху Снизу