Fix #5, disable AutoTNT for now
This commit is contained in:
@@ -29,7 +29,7 @@ public class MeteorRejectsAddon extends MeteorAddon {
|
|||||||
modules.add(new AutoExtinguish());
|
modules.add(new AutoExtinguish());
|
||||||
modules.add(new AutoHighway());
|
modules.add(new AutoHighway());
|
||||||
modules.add(new AutoPot());
|
modules.add(new AutoPot());
|
||||||
modules.add(new AutoTNT());
|
//modules.add(new AutoTNT());
|
||||||
modules.add(new Confuse());
|
modules.add(new Confuse());
|
||||||
modules.add(new InteractionMenu());
|
modules.add(new InteractionMenu());
|
||||||
modules.add(new Glide());
|
modules.add(new Glide());
|
||||||
|
|||||||
@@ -83,10 +83,11 @@ public class AutoTNT extends Module {
|
|||||||
if (ticks <= 0) {
|
if (ticks <= 0) {
|
||||||
// Clear and get tnt blocks
|
// Clear and get tnt blocks
|
||||||
blocks.clear();
|
blocks.clear();
|
||||||
for (BlockPos blockPos : BlockUtils.getSphere(mc.player.getBlockPos(), range.get(), range.get())) {
|
// TODO: Fix
|
||||||
bp.set(blockPos);
|
// for (BlockPos blockPos : BlockUtils.getSphere(mc.player.getBlockPos(), range.get(), range.get())) {
|
||||||
if (mc.world.getBlockState(blockPos).getBlock() instanceof TntBlock) blocks.add(bp);
|
// bp.set(blockPos);
|
||||||
}
|
// if (mc.world.getBlockState(blockPos).getBlock() instanceof TntBlock) blocks.add(bp);
|
||||||
|
// }
|
||||||
|
|
||||||
// Make sure there are TNTs around us
|
// Make sure there are TNTs around us
|
||||||
if (blocks.size() <= 0) {
|
if (blocks.size() <= 0) {
|
||||||
@@ -144,4 +145,5 @@ public class AutoTNT extends Module {
|
|||||||
private void setBpToVec3d(Vec3d pos) {
|
private void setBpToVec3d(Vec3d pos) {
|
||||||
bp.set(pos.getX(), pos.getY(), pos.getZ());
|
bp.set(pos.getX(), pos.getY(), pos.getZ());
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -6,15 +6,19 @@ import meteordevelopment.orbit.EventHandler;
|
|||||||
import minegame159.meteorclient.events.render.RenderEvent;
|
import minegame159.meteorclient.events.render.RenderEvent;
|
||||||
import minegame159.meteorclient.settings.*;
|
import minegame159.meteorclient.settings.*;
|
||||||
import minegame159.meteorclient.systems.modules.Module;
|
import minegame159.meteorclient.systems.modules.Module;
|
||||||
|
import minegame159.meteorclient.utils.player.PlayerUtils;
|
||||||
import minegame159.meteorclient.utils.render.color.Color;
|
import minegame159.meteorclient.utils.render.color.Color;
|
||||||
import minegame159.meteorclient.utils.render.color.SettingColor;
|
import minegame159.meteorclient.utils.render.color.SettingColor;
|
||||||
|
|
||||||
import net.minecraft.client.model.ModelPart;
|
import net.minecraft.client.model.ModelPart;
|
||||||
|
import net.minecraft.client.options.Perspective;
|
||||||
import net.minecraft.client.render.*;
|
import net.minecraft.client.render.*;
|
||||||
import net.minecraft.client.render.entity.LivingEntityRenderer;
|
import net.minecraft.client.render.entity.LivingEntityRenderer;
|
||||||
import net.minecraft.client.render.entity.PlayerEntityRenderer;
|
import net.minecraft.client.render.entity.PlayerEntityRenderer;
|
||||||
import net.minecraft.client.render.entity.model.PlayerEntityModel;
|
import net.minecraft.client.render.entity.model.PlayerEntityModel;
|
||||||
import net.minecraft.client.util.math.MatrixStack;
|
import net.minecraft.client.util.math.MatrixStack;
|
||||||
import net.minecraft.client.util.math.Vector3f;
|
import net.minecraft.client.util.math.Vector3f;
|
||||||
|
import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.entity.player.PlayerEntity;
|
import net.minecraft.entity.player.PlayerEntity;
|
||||||
import net.minecraft.util.math.*;
|
import net.minecraft.util.math.*;
|
||||||
|
|
||||||
@@ -37,94 +41,95 @@ public class SkeletonESP extends Module {
|
|||||||
MatrixStack matrixStack = event.matrices;
|
MatrixStack matrixStack = event.matrices;
|
||||||
float g = event.tickDelta;
|
float g = event.tickDelta;
|
||||||
Render3DUtils.INSTANCE.setup3DRender(true);
|
Render3DUtils.INSTANCE.setup3DRender(true);
|
||||||
Color skeletonColor = skeletonColorSetting.get();
|
|
||||||
mc.world.getEntities().forEach(entity -> {
|
mc.world.getEntities().forEach(entity -> {
|
||||||
if (entity instanceof PlayerEntity && entity.getUuid() != mc.player.getUuid()) {
|
if (!(entity instanceof PlayerEntity)) return;
|
||||||
PlayerEntity playerEntity = (PlayerEntity) entity;
|
if (mc.options.getPerspective() == Perspective.FIRST_PERSON && (Entity)mc.player == entity) return;
|
||||||
|
|
||||||
Vec3d footPos = Render3DUtils.INSTANCE.getEntityRenderPosition(playerEntity, g);
|
Color skeletonColor = PlayerUtils.getPlayerColor((PlayerEntity)entity, skeletonColorSetting.get());
|
||||||
PlayerEntityRenderer livingEntityRenderer = (PlayerEntityRenderer)(LivingEntityRenderer) mc.getEntityRenderDispatcher().getRenderer(playerEntity);
|
PlayerEntity playerEntity = (PlayerEntity) entity;
|
||||||
PlayerEntityModel playerEntityModel = (PlayerEntityModel)livingEntityRenderer.getModel();
|
|
||||||
|
|
||||||
float h = MathHelper.lerpAngleDegrees(g, playerEntity.prevBodyYaw, playerEntity.bodyYaw);
|
Vec3d footPos = Render3DUtils.INSTANCE.getEntityRenderPosition(playerEntity, g);
|
||||||
float j = MathHelper.lerpAngleDegrees(g, playerEntity.prevHeadYaw, playerEntity.headYaw);
|
PlayerEntityRenderer livingEntityRenderer = (PlayerEntityRenderer)(LivingEntityRenderer) mc.getEntityRenderDispatcher().getRenderer(playerEntity);
|
||||||
|
PlayerEntityModel playerEntityModel = (PlayerEntityModel)livingEntityRenderer.getModel();
|
||||||
|
|
||||||
float q = playerEntity.limbAngle - playerEntity.limbDistance * (1.0F - g);
|
float h = MathHelper.lerpAngleDegrees(g, playerEntity.prevBodyYaw, playerEntity.bodyYaw);
|
||||||
float p = MathHelper.lerp(g, playerEntity.lastLimbDistance, playerEntity.limbDistance);
|
float j = MathHelper.lerpAngleDegrees(g, playerEntity.prevHeadYaw, playerEntity.headYaw);
|
||||||
float o = (float)playerEntity.age + g;
|
|
||||||
float k = j - h;
|
|
||||||
float m = MathHelper.lerp(g, playerEntity.prevPitch, playerEntity.pitch);
|
|
||||||
|
|
||||||
playerEntityModel.setAngles(playerEntity, q, p, o, k, m);
|
float q = playerEntity.limbAngle - playerEntity.limbDistance * (1.0F - g);
|
||||||
boolean sneaking = playerEntity.isSneaking();
|
float p = MathHelper.lerp(g, playerEntity.lastLimbDistance, playerEntity.limbDistance);
|
||||||
|
float o = (float)playerEntity.age + g;
|
||||||
|
float k = j - h;
|
||||||
|
float m = MathHelper.lerp(g, playerEntity.prevPitch, playerEntity.pitch);
|
||||||
|
|
||||||
ModelPart head = playerEntityModel.head;
|
playerEntityModel.setAngles(playerEntity, q, p, o, k, m);
|
||||||
ModelPart leftArm = playerEntityModel.leftArm;
|
boolean sneaking = playerEntity.isSneaking();
|
||||||
ModelPart rightArm = playerEntityModel.rightArm;
|
|
||||||
ModelPart leftLeg = playerEntityModel.leftLeg;
|
|
||||||
ModelPart rightLeg = playerEntityModel.rightLeg;
|
|
||||||
|
|
||||||
matrixStack.translate(footPos.x, footPos.y, footPos.z);
|
ModelPart head = playerEntityModel.head;
|
||||||
matrixStack.multiply(new Quaternion(new Vector3f(0, -1, 0), playerEntity.bodyYaw + 180, true));
|
ModelPart leftArm = playerEntityModel.leftArm;
|
||||||
BufferBuilder bufferBuilder = Tessellator.getInstance().getBuffer();
|
ModelPart rightArm = playerEntityModel.rightArm;
|
||||||
bufferBuilder.begin(1, VertexFormats.POSITION_COLOR);
|
ModelPart leftLeg = playerEntityModel.leftLeg;
|
||||||
|
ModelPart rightLeg = playerEntityModel.rightLeg;
|
||||||
|
|
||||||
Matrix4f matrix4f = matrixStack.peek().getModel();
|
matrixStack.translate(footPos.x, footPos.y, footPos.z);
|
||||||
bufferBuilder.vertex(matrix4f, 0, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
matrixStack.multiply(new Quaternion(new Vector3f(0, -1, 0), playerEntity.bodyYaw + 180, true));
|
||||||
bufferBuilder.vertex(matrix4f, 0, sneaking ? 1.05f : 1.4f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();//spine
|
BufferBuilder bufferBuilder = Tessellator.getInstance().getBuffer();
|
||||||
|
bufferBuilder.begin(1, VertexFormats.POSITION_COLOR);
|
||||||
|
|
||||||
bufferBuilder.vertex(matrix4f, -0.37f, sneaking ? 1.05f : 1.35f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();//shoulders
|
Matrix4f matrix4f = matrixStack.peek().getModel();
|
||||||
bufferBuilder.vertex(matrix4f, 0.37f, sneaking ? 1.05f : 1.35f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
|
bufferBuilder.vertex(matrix4f, 0, sneaking ? 1.05f : 1.4f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();//spine
|
||||||
|
|
||||||
bufferBuilder.vertex(matrix4f, -0.15f, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();//pelvis
|
bufferBuilder.vertex(matrix4f, -0.37f, sneaking ? 1.05f : 1.35f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();//shoulders
|
||||||
bufferBuilder.vertex(matrix4f, 0.15f, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0.37f, sneaking ? 1.05f : 1.35f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
|
|
||||||
matrixStack.push();//head
|
bufferBuilder.vertex(matrix4f, -0.15f, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();//pelvis
|
||||||
matrixStack.translate(0, sneaking ? 1.05f : 1.4f, 0);
|
bufferBuilder.vertex(matrix4f, 0.15f, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
rotate(matrixStack, head);
|
|
||||||
matrix4f = matrixStack.peek().getModel();
|
|
||||||
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
|
||||||
bufferBuilder.vertex(matrix4f, 0, 0.15f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
|
||||||
matrixStack.pop();
|
|
||||||
|
|
||||||
matrixStack.push();//right leg
|
matrixStack.push();//head
|
||||||
matrixStack.translate(0.15f, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0);
|
matrixStack.translate(0, sneaking ? 1.05f : 1.4f, 0);
|
||||||
rotate(matrixStack, rightLeg);
|
rotate(matrixStack, head);
|
||||||
matrix4f = matrixStack.peek().getModel();
|
matrix4f = matrixStack.peek().getModel();
|
||||||
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
bufferBuilder.vertex(matrix4f, 0, -0.6f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0, 0.15f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
matrixStack.pop();
|
matrixStack.pop();
|
||||||
|
|
||||||
matrixStack.push();//left leg
|
matrixStack.push();//right leg
|
||||||
matrixStack.translate(-0.15f, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0);
|
matrixStack.translate(0.15f, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0);
|
||||||
rotate(matrixStack, leftLeg);
|
rotate(matrixStack, rightLeg);
|
||||||
matrix4f = matrixStack.peek().getModel();
|
matrix4f = matrixStack.peek().getModel();
|
||||||
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
bufferBuilder.vertex(matrix4f, 0, -0.6f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0, -0.6f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
matrixStack.pop();
|
matrixStack.pop();
|
||||||
|
|
||||||
matrixStack.push();//right arm
|
matrixStack.push();//left leg
|
||||||
matrixStack.translate(0.37f, sneaking ? 1.05f : 1.35f, 0);
|
matrixStack.translate(-0.15f, sneaking ? 0.6f : 0.7f, sneaking ? 0.23f : 0);
|
||||||
rotate(matrixStack, rightArm);
|
rotate(matrixStack, leftLeg);
|
||||||
matrix4f = matrixStack.peek().getModel();
|
matrix4f = matrixStack.peek().getModel();
|
||||||
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
bufferBuilder.vertex(matrix4f, 0, -0.55f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0, -0.6f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
matrixStack.pop();
|
matrixStack.pop();
|
||||||
|
|
||||||
matrixStack.push();//left arm
|
matrixStack.push();//right arm
|
||||||
matrixStack.translate(-0.37f, sneaking ? 1.05f : 1.35f, 0);
|
matrixStack.translate(0.37f, sneaking ? 1.05f : 1.35f, 0);
|
||||||
rotate(matrixStack, leftArm);
|
rotate(matrixStack, rightArm);
|
||||||
matrix4f = matrixStack.peek().getModel();
|
matrix4f = matrixStack.peek().getModel();
|
||||||
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
bufferBuilder.vertex(matrix4f, 0, -0.55f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
bufferBuilder.vertex(matrix4f, 0, -0.55f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
matrixStack.pop();
|
matrixStack.pop();
|
||||||
|
|
||||||
bufferBuilder.end();
|
matrixStack.push();//left arm
|
||||||
BufferRenderer.draw(bufferBuilder);
|
matrixStack.translate(-0.37f, sneaking ? 1.05f : 1.35f, 0);
|
||||||
|
rotate(matrixStack, leftArm);
|
||||||
|
matrix4f = matrixStack.peek().getModel();
|
||||||
|
bufferBuilder.vertex(matrix4f, 0, 0, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
|
bufferBuilder.vertex(matrix4f, 0, -0.55f, 0).color(skeletonColor.r, skeletonColor.g, skeletonColor.b, skeletonColor.a).next();
|
||||||
|
matrixStack.pop();
|
||||||
|
|
||||||
matrixStack.multiply(new Quaternion(new Vector3f(0, 1, 0), playerEntity.bodyYaw + 180, true));
|
bufferBuilder.end();
|
||||||
matrixStack.translate(-footPos.x, -footPos.y, -footPos.z);
|
BufferRenderer.draw(bufferBuilder);
|
||||||
}
|
|
||||||
|
matrixStack.multiply(new Quaternion(new Vector3f(0, 1, 0), playerEntity.bodyYaw + 180, true));
|
||||||
|
matrixStack.translate(-footPos.x, -footPos.y, -footPos.z);
|
||||||
});
|
});
|
||||||
Render3DUtils.INSTANCE.end3DRender();
|
Render3DUtils.INSTANCE.end3DRender();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user