0
0
mirror of https://github.com/Wurst-Imperium/Wurst7.git synced 2024-09-19 17:02:13 +02:00

Merge v7.40 into 1.20

This commit is contained in:
Alexander01998 2024-02-28 19:45:55 +01:00
parent affbfcf5c6
commit 6bd5f39db0
45 changed files with 607 additions and 151 deletions

View File

@ -13,7 +13,7 @@ loader_version=0.15.7
fabric_version=0.83.0+1.20
# Mod Properties
mod_version = v7.39.1-MC1.20
mod_version = v7.40-MC1.20
maven_group = net.wurstclient
archives_base_name = Wurst-Client

View File

@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME

16
gradlew vendored
View File

@ -145,7 +145,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
case $MAX_FD in #(
max*)
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
# shellcheck disable=SC3045
# shellcheck disable=SC2039,SC3045
MAX_FD=$( ulimit -H -n ) ||
warn "Could not query maximum file descriptor limit"
esac
@ -153,7 +153,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
'' | soft) :;; #(
*)
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
# shellcheck disable=SC3045
# shellcheck disable=SC2039,SC3045
ulimit -n "$MAX_FD" ||
warn "Could not set maximum file descriptor limit to $MAX_FD"
esac
@ -202,11 +202,11 @@ fi
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
# Collect all arguments for the java command;
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
# shell script including quotes and variable substitutions, so put them in
# double quotes to make sure that they get re-expanded; and
# * put everything else in single quotes, so that it's not re-expanded.
# Collect all arguments for the java command:
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
# and any embedded shellness will be escaped.
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
# treated as '${Hostname}' itself on the command line.
set -- \
"-Dorg.gradle.appname=$APP_BASE_NAME" \
@ -246,4 +246,4 @@ eval "set -- $(
tr '\n' ' '
)" '"$@"'
exec "$JAVACMD" "$@"
exec "$JAVACMD" "$@"

View File

@ -57,7 +57,7 @@ public enum WurstClient
public static MinecraftClient MC;
public static IMinecraftClient IMC;
public static final String VERSION = "7.39.1";
public static final String VERSION = "7.40";
public static final String MC_VERSION = "1.20";
private WurstAnalytics analytics;

View File

@ -138,6 +138,8 @@ public final class HackList implements UpdateListener
public final NoLevitationHack noLevitationHack = new NoLevitationHack();
public final NoOverlayHack noOverlayHack = new NoOverlayHack();
public final NoPumpkinHack noPumpkinHack = new NoPumpkinHack();
public final NoShieldOverlayHack noShieldOverlayHack =
new NoShieldOverlayHack();
public final NoSlowdownHack noSlowdownHack = new NoSlowdownHack();
public final NoWeatherHack noWeatherHack = new NoWeatherHack();
public final NoWebHack noWebHack = new NoWebHack();
@ -148,6 +150,7 @@ public final class HackList implements UpdateListener
public final PanicHack panicHack = new PanicHack();
public final ParkourHack parkourHack = new ParkourHack();
public final PlayerEspHack playerEspHack = new PlayerEspHack();
public final PortalEspHack portalEspHack = new PortalEspHack();
public final PortalGuiHack portalGuiHack = new PortalGuiHack();
public final PotionSaverHack potionSaverHack = new PotionSaverHack();
public final ProphuntEspHack prophuntEspHack = new ProphuntEspHack();
@ -160,7 +163,6 @@ public final class HackList implements UpdateListener
public final SafeWalkHack safeWalkHack = new SafeWalkHack();
public final ScaffoldWalkHack scaffoldWalkHack = new ScaffoldWalkHack();
public final SearchHack searchHack = new SearchHack();
public final ServerCrasherHack serverCrasherHack = new ServerCrasherHack();
public final SkinDerpHack skinDerpHack = new SkinDerpHack();
public final SneakHack sneakHack = new SneakHack();
public final SnowShoeHack snowShoeHack = new SnowShoeHack();

View File

@ -150,7 +150,7 @@ public final class AimAssistHack extends Hack
return;
}
WURST.getHax().autoSwordHack.setSlot();
WURST.getHax().autoSwordHack.setSlot(target);
faceEntityClient(target);
}

View File

@ -20,13 +20,15 @@ public final class AntiKnockbackHack extends Hack implements KnockbackListener
{
private final SliderSetting hStrength =
new SliderSetting("Horizontal Strength",
"How far to reduce horizontal knockback.\n" + "100% = no knockback",
1, 0.01, 1, 0.01, ValueDisplay.PERCENTAGE);
"How far to reduce horizontal knockback.\n"
+ "100% = no knockback\n" + ">100% = reverse knockback",
1, 0.01, 2, 0.01, ValueDisplay.PERCENTAGE);
private final SliderSetting vStrength =
new SliderSetting("Vertical Strength",
"How far to reduce vertical knockback.\n" + "100% = no knockback",
1, 0.01, 1, 0.01, ValueDisplay.PERCENTAGE);
"How far to reduce vertical knockback.\n" + "100% = no knockback\n"
+ ">100% = reverse knockback",
1, 0.01, 2, 0.01, ValueDisplay.PERCENTAGE);
public AntiKnockbackHack()
{

View File

@ -12,14 +12,19 @@ import net.wurstclient.Category;
import net.wurstclient.SearchTags;
import net.wurstclient.events.UpdateListener;
import net.wurstclient.hack.Hack;
import net.wurstclient.settings.CheckboxSetting;
@SearchTags({"auto sprint"})
public final class AutoSprintHack extends Hack implements UpdateListener
{
private final CheckboxSetting hungry = new CheckboxSetting("Hungry Sprint",
"Sprint even on low hunger.", false);
public AutoSprintHack()
{
super("AutoSprint");
setCategory(Category.MOVEMENT);
addSetting(hungry);
}
@Override
@ -48,4 +53,9 @@ public final class AutoSprintHack extends Hack implements UpdateListener
if(player.forwardSpeed > 0)
player.setSprinting(true);
}
public boolean shouldSprintHungry()
{
return isEnabled() && hungry.isChecked();
}
}

View File

@ -7,12 +7,16 @@
*/
package net.wurstclient.hacks;
import net.minecraft.enchantment.EnchantmentHelper;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityGroup;
import net.minecraft.entity.LivingEntity;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.item.MiningToolItem;
import net.minecraft.item.SwordItem;
import net.minecraft.item.ToolItem;
import net.minecraft.item.TridentItem;
import net.minecraft.util.hit.EntityHitResult;
import net.minecraft.util.hit.HitResult;
import net.wurstclient.Category;
@ -33,12 +37,13 @@ public final class AutoSwordHack extends Hack implements UpdateListener
new EnumSetting<>("Priority", Priority.values(), Priority.SPEED);
private final CheckboxSetting switchBack = new CheckboxSetting(
"Switch back",
"Switches back to the previously selected slot after \u00a7lRelease time\u00a7r has passed.",
"Switch back", "Switches back to the previously selected slot after"
+ " \u00a7lRelease time\u00a7r has passed.",
true);
private final SliderSetting releaseTime = new SliderSetting("Release time",
"Time until AutoSword will switch back from the weapon to the previously selected slot.\n\n"
"Time until AutoSword will switch back from the weapon to the"
+ " previously selected slot.\n\n"
+ "Only works when \u00a7lSwitch back\u00a7r is checked.",
10, 1, 200, 1,
ValueDisplay.INTEGER.withSuffix(" ticks").withLabel(1, "1 tick"));
@ -80,7 +85,7 @@ public final class AutoSwordHack extends Hack implements UpdateListener
if(entity instanceof LivingEntity
&& EntityUtils.IS_ATTACKABLE.test(entity))
setSlot();
setSlot(entity);
}
// update timer
@ -93,7 +98,7 @@ public final class AutoSwordHack extends Hack implements UpdateListener
resetSlot();
}
public void setSlot()
public void setSlot(Entity entity)
{
// check if active
if(!isEnabled())
@ -112,10 +117,9 @@ public final class AutoSwordHack extends Hack implements UpdateListener
if(MC.player.getInventory().getStack(i).isEmpty())
continue;
Item item = MC.player.getInventory().getStack(i).getItem();
// get damage
float value = getValue(item);
// get weapon value
ItemStack stack = MC.player.getInventory().getStack(i);
float value = getValue(stack, entity);
// compare with previous best weapon
if(value > bestValue)
@ -140,21 +144,28 @@ public final class AutoSwordHack extends Hack implements UpdateListener
timer = releaseTime.getValueI();
}
private float getValue(Item item)
private float getValue(ItemStack stack, Entity entity)
{
Item item = stack.getItem();
if(!(item instanceof ToolItem || item instanceof TridentItem))
return Integer.MIN_VALUE;
switch(priority.getSelected())
{
case SPEED:
if(item instanceof ToolItem tool)
return ItemUtils.getAttackSpeed(tool);
break;
return ItemUtils.getAttackSpeed(item);
case DAMAGE:
EntityGroup group = entity instanceof LivingEntity le
? le.getGroup() : EntityGroup.DEFAULT;
float dmg = EnchantmentHelper.getAttackDamage(stack, group);
if(item instanceof SwordItem sword)
return sword.getAttackDamage();
if(item instanceof MiningToolItem miningTool)
return miningTool.getAttackDamage();
break;
dmg += sword.getAttackDamage();
if(item instanceof MiningToolItem tool)
dmg += tool.getAttackDamage();
if(item instanceof TridentItem)
dmg += TridentItem.ATTACK_DAMAGE;
return dmg;
}
return Integer.MIN_VALUE;

View File

@ -131,7 +131,7 @@ public final class ClickAuraHack extends Hack
if(target == null)
return;
WURST.getHax().autoSwordHack.setSlot();
WURST.getHax().autoSwordHack.setSlot(target);
// face entity
Rotation rotation = RotationUtils

View File

@ -134,7 +134,7 @@ public final class FightBotHack extends Hack
if(entity == null)
return;
WURST.getHax().autoSwordHack.setSlot();
WURST.getHax().autoSwordHack.setSlot(entity);
if(useAi.isChecked())
{

View File

@ -81,10 +81,7 @@ public final class FullbrightHack extends Hack implements UpdateListener
private void updateGamma()
{
boolean shouldChangeGamma =
isEnabled() && method.getSelected() == Method.GAMMA;
if(shouldChangeGamma)
if(isChangingGamma())
{
setGamma(16);
return;
@ -163,6 +160,11 @@ public final class FullbrightHack extends Hack implements UpdateListener
return nightVisionStrength;
}
public boolean isChangingGamma()
{
return isEnabled() && method.getSelected() == Method.GAMMA;
}
/**
* Returns the value of Fullbright's "Default brightness" slider. Used by
* {@link XRayHack} to restore the gamma value when X-Ray is turned off.

View File

@ -158,7 +158,7 @@ public final class KillauraHack extends Hack
if(target == null)
return;
WURST.getHax().autoSwordHack.setSlot();
WURST.getHax().autoSwordHack.setSlot(target);
Vec3d hitVec = target.getBoundingBox().getCenter();
if(checkLOS.isChecked() && !BlockUtils.hasLineOfSight(hitVec))

View File

@ -178,7 +178,7 @@ public final class KillauraLegitHack extends Hack
if(target == null)
return;
WURST.getHax().autoSwordHack.setSlot();
WURST.getHax().autoSwordHack.setSlot(target);
// check line of sight
if(!BlockUtils.hasLineOfSight(target.getBoundingBox().getCenter()))

View File

@ -111,7 +111,7 @@ public final class MultiAuraHack extends Hack implements UpdateListener
if(entities.isEmpty())
return;
WURST.getHax().autoSwordHack.setSlot();
WURST.getHax().autoSwordHack.setSlot(entities.get(0));
// attack entities
for(Entity entity : entities)

View File

@ -0,0 +1,48 @@
/*
* Copyright (c) 2014-2023 Wurst-Imperium and contributors.
*
* This source code is subject to the terms of the GNU General Public
* License, version 3. If a copy of the GPL was not distributed with this
* file, You can obtain one at: https://www.gnu.org/licenses/gpl-3.0.txt
*/
package net.wurstclient.hacks;
import net.minecraft.client.util.math.MatrixStack;
import net.wurstclient.Category;
import net.wurstclient.hack.Hack;
import net.wurstclient.settings.SliderSetting;
import net.wurstclient.settings.SliderSetting.ValueDisplay;
public final class NoShieldOverlayHack extends Hack
{
public final SliderSetting blockingOffset =
new SliderSetting("Blocking offset",
"The amount to lower the shield overlay by when blocking.", 0.5, 0,
0.8, 0.01, ValueDisplay.DECIMAL);
public final SliderSetting nonBlockingOffset =
new SliderSetting("Non-blocking offset",
"The amount to lower the shield overlay when not blocking.", 0.2, 0,
0.5, 0.01, ValueDisplay.DECIMAL);
public NoShieldOverlayHack()
{
super("NoShieldOverlay");
setCategory(Category.RENDER);
addSetting(blockingOffset);
addSetting(nonBlockingOffset);
}
public void adjustShieldPosition(MatrixStack matrixStack, boolean blocking)
{
if(!isEnabled())
return;
if(blocking)
matrixStack.translate(0, -blockingOffset.getValue(), 0);
else
matrixStack.translate(0, -nonBlockingOffset.getValue(), 0);
}
// See HeldItemRendererMixin
}

View File

@ -0,0 +1,196 @@
/*
* Copyright (c) 2014-2023 Wurst-Imperium and contributors.
*
* This source code is subject to the terms of the GNU General Public
* License, version 3. If a copy of the GPL was not distributed with this
* file, You can obtain one at: https://www.gnu.org/licenses/gpl-3.0.txt
*/
package net.wurstclient.hacks;
import java.awt.Color;
import java.util.Arrays;
import java.util.List;
import java.util.function.BiPredicate;
import org.lwjgl.opengl.GL11;
import com.mojang.blaze3d.systems.RenderSystem;
import net.minecraft.block.BlockState;
import net.minecraft.block.Blocks;
import net.minecraft.client.render.GameRenderer;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.util.math.BlockPos;
import net.wurstclient.Category;
import net.wurstclient.events.CameraTransformViewBobbingListener;
import net.wurstclient.events.PacketInputListener;
import net.wurstclient.events.RenderListener;
import net.wurstclient.events.UpdateListener;
import net.wurstclient.hack.Hack;
import net.wurstclient.hacks.portalesp.PortalEspBlockGroup;
import net.wurstclient.hacks.portalesp.PortalEspRenderer;
import net.wurstclient.settings.CheckboxSetting;
import net.wurstclient.settings.ChunkAreaSetting;
import net.wurstclient.settings.ColorSetting;
import net.wurstclient.settings.EspStyleSetting;
import net.wurstclient.util.ChunkSearcher.Result;
import net.wurstclient.util.ChunkSearcherCoordinator;
import net.wurstclient.util.RenderUtils;
public final class PortalEspHack extends Hack implements UpdateListener,
CameraTransformViewBobbingListener, RenderListener
{
private final EspStyleSetting style = new EspStyleSetting();
private final PortalEspBlockGroup netherPortal =
new PortalEspBlockGroup(Blocks.NETHER_PORTAL,
new ColorSetting("Nether portal color",
"Nether portals will be highlighted in this color.", Color.RED),
new CheckboxSetting("Include nether portals", true));
private final PortalEspBlockGroup endPortal =
new PortalEspBlockGroup(Blocks.END_PORTAL,
new ColorSetting("End portal color",
"End portals will be highlighted in this color.", Color.GREEN),
new CheckboxSetting("Include end portals", true));
private final PortalEspBlockGroup endPortalFrame = new PortalEspBlockGroup(
Blocks.END_PORTAL_FRAME,
new ColorSetting("End portal frame color",
"End portal frames will be highlighted in this color.", Color.BLUE),
new CheckboxSetting("Include end portal frames", true));
private final PortalEspBlockGroup endGateway = new PortalEspBlockGroup(
Blocks.END_GATEWAY,
new ColorSetting("End gateway color",
"End gateways will be highlighted in this color.", Color.YELLOW),
new CheckboxSetting("Include end gateways", true));
private final List<PortalEspBlockGroup> groups =
Arrays.asList(netherPortal, endPortal, endPortalFrame, endGateway);
private final ChunkAreaSetting area = new ChunkAreaSetting("Area",
"The area around the player to search in.\n"
+ "Higher values require a faster computer.");
private final BiPredicate<BlockPos, BlockState> query =
(pos, state) -> state.getBlock() == Blocks.NETHER_PORTAL
|| state.getBlock() == Blocks.END_PORTAL
|| state.getBlock() == Blocks.END_PORTAL_FRAME
|| state.getBlock() == Blocks.END_GATEWAY;
private final ChunkSearcherCoordinator coordinator =
new ChunkSearcherCoordinator(query, area);
private boolean groupsUpToDate;
public PortalEspHack()
{
super("PortalESP");
setCategory(Category.RENDER);
addSetting(style);
groups.stream().flatMap(PortalEspBlockGroup::getSettings)
.forEach(this::addSetting);
addSetting(area);
}
@Override
public void onEnable()
{
groupsUpToDate = false;
EVENTS.add(UpdateListener.class, this);
EVENTS.add(PacketInputListener.class, coordinator);
EVENTS.add(CameraTransformViewBobbingListener.class, this);
EVENTS.add(RenderListener.class, this);
PortalEspRenderer.prepareBuffers();
}
@Override
public void onDisable()
{
EVENTS.remove(UpdateListener.class, this);
EVENTS.remove(PacketInputListener.class, coordinator);
EVENTS.remove(CameraTransformViewBobbingListener.class, this);
EVENTS.remove(RenderListener.class, this);
coordinator.reset();
groups.forEach(PortalEspBlockGroup::clear);
PortalEspRenderer.closeBuffers();
}
@Override
public void onCameraTransformViewBobbing(
CameraTransformViewBobbingEvent event)
{
if(style.getSelected().hasLines())
event.cancel();
}
@Override
public void onUpdate()
{
boolean searchersChanged = coordinator.update();
if(searchersChanged)
groupsUpToDate = false;
if(!groupsUpToDate && coordinator.isDone())
updateGroupBoxes();
}
@Override
public void onRender(MatrixStack matrixStack, float partialTicks)
{
// GL settings
GL11.glEnable(GL11.GL_BLEND);
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
GL11.glEnable(GL11.GL_CULL_FACE);
GL11.glDisable(GL11.GL_DEPTH_TEST);
matrixStack.push();
RenderUtils.applyRegionalRenderOffset(matrixStack);
PortalEspRenderer espRenderer =
new PortalEspRenderer(matrixStack, partialTicks);
if(style.getSelected().hasBoxes())
{
RenderSystem.setShader(GameRenderer::getPositionProgram);
groups.stream().filter(PortalEspBlockGroup::isEnabled)
.forEach(espRenderer::renderBoxes);
}
if(style.getSelected().hasLines())
{
RenderSystem.setShader(GameRenderer::getPositionProgram);
groups.stream().filter(PortalEspBlockGroup::isEnabled)
.forEach(espRenderer::renderLines);
}
matrixStack.pop();
// GL resets
RenderSystem.setShaderColor(1, 1, 1, 1);
GL11.glEnable(GL11.GL_DEPTH_TEST);
GL11.glDisable(GL11.GL_BLEND);
}
private void updateGroupBoxes()
{
groups.forEach(PortalEspBlockGroup::clear);
coordinator.getMatches().forEach(this::addToGroupBoxes);
groupsUpToDate = true;
}
private void addToGroupBoxes(Result result)
{
for(PortalEspBlockGroup group : groups)
if(result.state().getBlock() == group.getBlock())
{
group.add(result.pos());
break;
}
}
}

View File

@ -272,7 +272,7 @@ public final class ProtectHack extends Hack
if(target == enemy)
{
WURST.getHax().autoSwordHack.setSlot();
WURST.getHax().autoSwordHack.setSlot(enemy);
// check cooldown
if(!speed.isTimeToAttack())

View File

@ -31,6 +31,7 @@ import net.minecraft.client.render.VertexFormats;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.util.math.BlockPos;
import net.wurstclient.Category;
import net.wurstclient.SearchTags;
import net.wurstclient.events.PacketInputListener;
import net.wurstclient.events.RenderListener;
import net.wurstclient.events.UpdateListener;
@ -47,6 +48,7 @@ import net.wurstclient.util.RegionPos;
import net.wurstclient.util.RenderUtils;
import net.wurstclient.util.RotationUtils;
@SearchTags({"BlockESP", "block esp"})
public final class SearchHack extends Hack
implements UpdateListener, RenderListener
{

View File

@ -1,81 +0,0 @@
/*
* Copyright (c) 2014-2023 Wurst-Imperium and contributors.
*
* This source code is subject to the terms of the GNU General Public
* License, version 3. If a copy of the GPL was not distributed with this
* file, You can obtain one at: https://www.gnu.org/licenses/gpl-3.0.txt
*/
package net.wurstclient.hacks;
import com.mojang.brigadier.exceptions.CommandSyntaxException;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NbtCompound;
import net.minecraft.nbt.StringNbtReader;
import net.minecraft.network.packet.c2s.play.CreativeInventoryActionC2SPacket;
import net.minecraft.registry.Registries;
import net.minecraft.util.Identifier;
import net.wurstclient.Category;
import net.wurstclient.SearchTags;
import net.wurstclient.hack.Hack;
import net.wurstclient.util.ChatUtils;
@SearchTags({"server crasher", "ServerCrepperSpawnEgg",
"server creeper spawn egg"})
public final class ServerCrasherHack extends Hack
{
public ServerCrasherHack()
{
super("ServerCrasher");
setCategory(Category.ITEMS);
}
@Override
public void onEnable()
{
if(!MC.player.getAbilities().creativeMode)
{
ChatUtils.error("Creative mode only.");
setEnabled(false);
return;
}
Item item = Registries.ITEM.get(new Identifier("creeper_spawn_egg"));
ItemStack stack = new ItemStack(item, 1);
stack.setNbt(createNBT());
placeStackInHotbar(stack);
setEnabled(false);
}
private NbtCompound createNBT()
{
try
{
return StringNbtReader.parse(
"{display:{Lore:['\"\u00a7r1. Place item in dispenser.\"','\"\u00a7r2. Dispense item.\"','\"\u00a7r3. Ssss... BOOM!\"'],Name:'{\"text\":\"\u00a7rServer Creeper\"}'},EntityTag:{CustomName:\"TEST\",id:\"Creeper\",CustomNameVisible:1}}");
}catch(CommandSyntaxException e)
{
throw new RuntimeException(e);
}
}
private void placeStackInHotbar(ItemStack stack)
{
for(int i = 0; i < 9; i++)
{
if(!MC.player.getInventory().getStack(i).isEmpty())
continue;
MC.player.networkHandler.sendPacket(
new CreativeInventoryActionC2SPacket(36 + i, stack));
ChatUtils.message("Item created.");
return;
}
ChatUtils.error("Please clear a slot in your hotbar.");
}
}

View File

@ -116,7 +116,7 @@ public final class TpAuraHack extends Hack implements UpdateListener
if(entity == null)
return;
WURST.getHax().autoSwordHack.setSlot();
WURST.getHax().autoSwordHack.setSlot(entity);
// teleport
player.setPosition(entity.getX() + random.nextInt(3) * 2 - 2,

View File

@ -98,7 +98,7 @@ public final class TriggerBotHack extends Hack implements UpdateListener
if(!isCorrectEntity(target))
return;
WURST.getHax().autoSwordHack.setSlot();
WURST.getHax().autoSwordHack.setSlot(target);
WURST.getHax().criticalsHack.doCritical();
MC.interactionManager.attackEntity(player, target);

View File

@ -133,7 +133,7 @@ public final class XRayHack extends Hack implements UpdateListener,
// reset gamma
FullbrightHack fullbright = WURST.getHax().fullbrightHack;
if(!fullbright.isEnabled())
if(!fullbright.isChangingGamma())
ISimpleOption.get(MC.options.getGamma())
.forceSetValue(fullbright.getDefaultGamma());
}

View File

@ -0,0 +1,86 @@
/*
* Copyright (c) 2014-2023 Wurst-Imperium and contributors.
*
* This source code is subject to the terms of the GNU General Public
* License, version 3. If a copy of the GPL was not distributed with this
* file, You can obtain one at: https://www.gnu.org/licenses/gpl-3.0.txt
*/
package net.wurstclient.hacks.portalesp;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Objects;
import java.util.stream.Stream;
import net.minecraft.block.Block;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.Box;
import net.wurstclient.settings.CheckboxSetting;
import net.wurstclient.settings.ColorSetting;
import net.wurstclient.settings.Setting;
import net.wurstclient.util.BlockUtils;
public final class PortalEspBlockGroup
{
protected final ArrayList<Box> boxes = new ArrayList<>();
private final Block block;
private final ColorSetting color;
private final CheckboxSetting enabled;
public PortalEspBlockGroup(Block block, ColorSetting color,
CheckboxSetting enabled)
{
this.block = block;
this.color = Objects.requireNonNull(color);
this.enabled = enabled;
}
public void add(BlockPos pos)
{
Box box = getBox(pos);
if(box == null)
return;
boxes.add(box);
}
private Box getBox(BlockPos pos)
{
if(!BlockUtils.canBeClicked(pos))
return null;
return BlockUtils.getBoundingBox(pos);
}
public void clear()
{
boxes.clear();
}
public boolean isEnabled()
{
return enabled == null || enabled.isChecked();
}
public Stream<Setting> getSettings()
{
return Stream.of(enabled, color).filter(Objects::nonNull);
}
public Block getBlock()
{
return block;
}
public float[] getColorF()
{
return color.getColorF();
}
public List<Box> getBoxes()
{
return Collections.unmodifiableList(boxes);
}
}

View File

@ -0,0 +1,124 @@
/*
* Copyright (c) 2014-2023 Wurst-Imperium and contributors.
*
* This source code is subject to the terms of the GNU General Public
* License, version 3. If a copy of the GPL was not distributed with this
* file, You can obtain one at: https://www.gnu.org/licenses/gpl-3.0.txt
*/
package net.wurstclient.hacks.portalesp;
import java.util.Objects;
import java.util.stream.Stream;
import org.joml.Matrix4f;
import com.mojang.blaze3d.systems.RenderSystem;
import net.minecraft.client.gl.ShaderProgram;
import net.minecraft.client.gl.VertexBuffer;
import net.minecraft.client.render.BufferBuilder;
import net.minecraft.client.render.Tessellator;
import net.minecraft.client.render.VertexFormat;
import net.minecraft.client.render.VertexFormats;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.Box;
import net.minecraft.util.math.Vec3d;
import net.wurstclient.util.RegionPos;
import net.wurstclient.util.RenderUtils;
import net.wurstclient.util.RotationUtils;
public final class PortalEspRenderer
{
private static VertexBuffer solidBox;
private static VertexBuffer outlinedBox;
private final MatrixStack matrixStack;
private final RegionPos region;
private final Vec3d start;
public PortalEspRenderer(MatrixStack matrixStack, float partialTicks)
{
this.matrixStack = matrixStack;
region = RenderUtils.getCameraRegion();
start = RotationUtils.getClientLookVec(partialTicks)
.add(RenderUtils.getCameraPos()).subtract(region.toVec3d());
}
public void renderBoxes(PortalEspBlockGroup group)
{
float[] colorF = group.getColorF();
for(Box box : group.getBoxes())
{
matrixStack.push();
matrixStack.translate(box.minX - region.x(), box.minY,
box.minZ - region.z());
matrixStack.scale((float)(box.maxX - box.minX),
(float)(box.maxY - box.minY), (float)(box.maxZ - box.minZ));
Matrix4f viewMatrix = matrixStack.peek().getPositionMatrix();
Matrix4f projMatrix = RenderSystem.getProjectionMatrix();
ShaderProgram shader = RenderSystem.getShader();
RenderSystem.setShaderColor(colorF[0], colorF[1], colorF[2], 0.25F);
solidBox.bind();
solidBox.draw(viewMatrix, projMatrix, shader);
VertexBuffer.unbind();
RenderSystem.setShaderColor(colorF[0], colorF[1], colorF[2], 0.5F);
outlinedBox.bind();
outlinedBox.draw(viewMatrix, projMatrix, shader);
VertexBuffer.unbind();
matrixStack.pop();
}
}
public void renderLines(PortalEspBlockGroup group)
{
Matrix4f matrix = matrixStack.peek().getPositionMatrix();
Tessellator tessellator = RenderSystem.renderThreadTesselator();
BufferBuilder bufferBuilder = tessellator.getBuffer();
float[] colorF = group.getColorF();
RenderSystem.setShaderColor(colorF[0], colorF[1], colorF[2], 0.5F);
bufferBuilder.begin(VertexFormat.DrawMode.DEBUG_LINES,
VertexFormats.POSITION);
for(Box box : group.getBoxes())
{
Vec3d end = box.getCenter().subtract(region.toVec3d());
bufferBuilder
.vertex(matrix, (float)start.x, (float)start.y, (float)start.z)
.next();
bufferBuilder
.vertex(matrix, (float)end.x, (float)end.y, (float)end.z)
.next();
}
tessellator.draw();
}
public static void prepareBuffers()
{
closeBuffers();
solidBox = new VertexBuffer(VertexBuffer.Usage.STATIC);
outlinedBox = new VertexBuffer(VertexBuffer.Usage.STATIC);
Box box = new Box(BlockPos.ORIGIN);
RenderUtils.drawSolidBox(box, solidBox);
RenderUtils.drawOutlinedBox(box, outlinedBox);
}
public static void closeBuffers()
{
Stream.of(solidBox, outlinedBox).filter(Objects::nonNull)
.forEach(VertexBuffer::close);
}
}

View File

@ -39,6 +39,10 @@ public final class KeybindProcessor implements KeyPressListener
if(event.getAction() != GLFW.GLFW_PRESS)
return;
if(InputUtil.isKeyPressed(WurstClient.MC.getWindow().getHandle(),
GLFW.GLFW_KEY_F3))
return;
Screen screen = WurstClient.MC.currentScreen;
if(screen != null && !(screen instanceof ClickGuiScreen))
return;

View File

@ -169,6 +169,17 @@ public class ClientPlayerEntityMixin extends AbstractClientPlayerEntity
tempCurrentScreen = null;
}
/**
* This mixin allows AutoSprint to enable sprinting even when the player is
* too hungry.
*/
@Inject(at = @At("HEAD"), method = "canSprint()Z", cancellable = true)
private void onCanSprint(CallbackInfoReturnable<Boolean> cir)
{
if(WurstClient.INSTANCE.getHax().autoSprintHack.shouldSprintHungry())
cir.setReturnValue(true);
}
/**
* Getter method for what used to be airStrafingSpeed.
* Overridden to allow for the speed to be modified by hacks.

View File

@ -0,0 +1,55 @@
/*
* Copyright (c) 2014-2023 Wurst-Imperium and contributors.
*
* This source code is subject to the terms of the GNU General Public
* License, version 3. If a copy of the GPL was not distributed with this
* file, You can obtain one at: https://www.gnu.org/licenses/gpl-3.0.txt
*/
package net.wurstclient.mixin;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
import net.minecraft.client.network.AbstractClientPlayerEntity;
import net.minecraft.client.render.VertexConsumerProvider;
import net.minecraft.client.render.item.HeldItemRenderer;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.item.ItemStack;
import net.minecraft.item.Items;
import net.minecraft.util.Hand;
import net.wurstclient.WurstClient;
@Mixin(HeldItemRenderer.class)
public abstract class HeldItemRendererMixin
{
@Inject(at = {@At(value = "INVOKE",
target = "Lnet/minecraft/client/render/item/HeldItemRenderer;applyEquipOffset(Lnet/minecraft/client/util/math/MatrixStack;Lnet/minecraft/util/Arm;F)V",
ordinal = 4)}, method = "renderFirstPersonItem")
private void onApplyEquipOffsetBlocking(AbstractClientPlayerEntity player,
float tickDelta, float pitch, Hand hand, float swingProgress,
ItemStack item, float equipProgress, MatrixStack matrices,
VertexConsumerProvider vertexConsumers, int light, CallbackInfo ci)
{
// lower shield when blocking
if(item.getItem() == Items.SHIELD)
WurstClient.INSTANCE.getHax().noShieldOverlayHack
.adjustShieldPosition(matrices, true);
}
@Inject(at = {@At(value = "INVOKE",
target = "Lnet/minecraft/client/render/item/HeldItemRenderer;applySwingOffset(Lnet/minecraft/client/util/math/MatrixStack;Lnet/minecraft/util/Arm;F)V",
ordinal = 1)}, method = "renderFirstPersonItem")
private void onApplySwingOffsetNotBlocking(
AbstractClientPlayerEntity player, float tickDelta, float pitch,
Hand hand, float swingProgress, ItemStack item, float equipProgress,
MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light,
CallbackInfo ci)
{
// lower shield when not blocking
if(item.getItem() == Items.SHIELD)
WurstClient.INSTANCE.getHax().noShieldOverlayHack
.adjustShieldPosition(matrices, false);
}
}

View File

@ -49,12 +49,6 @@ public enum DefaultAutoBuildTemplates
new int[][]{{0, 0, 0}, {0, 1, 0}, {0, 2, 0}, {0, 3, 0}, {0, 4, 0},
{0, 5, 0}, {0, 6, 0}}),
SWASTIKA("Swastika",
new int[][]{{0, 0, 0}, {1, 0, 0}, {2, 0, 0}, {0, 1, 0}, {0, 2, 0},
{1, 2, 0}, {2, 2, 0}, {2, 3, 0}, {2, 4, 0}, {0, 3, 0}, {0, 4, 0},
{-1, 4, 0}, {-2, 4, 0}, {-1, 2, 0}, {-2, 2, 0}, {-2, 1, 0},
{-2, 0, 0}}),
TREE("Tree", new int[][]{{0, 0, 0}, {0, 1, 0}, {0, 2, 0}, {0, 3, 0},
{0, 4, 0}, {0, 3, -1}, {0, 3, 1}, {-1, 3, 0}, {1, 3, 0}, {0, 5, 0},
{0, 4, -1}, {0, 4, 1}, {-1, 4, 0}, {1, 4, 0}, {0, 3, -2}, {-1, 3, -1},

View File

@ -13,7 +13,6 @@ import net.minecraft.entity.EquipmentSlot;
import net.minecraft.entity.attribute.EntityAttributes;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.item.ToolItem;
import net.minecraft.nbt.NbtCompound;
import net.minecraft.nbt.NbtElement;
import net.minecraft.nbt.NbtList;
@ -56,7 +55,7 @@ public enum ItemUtils
}
}
public static float getAttackSpeed(ToolItem item)
public static float getAttackSpeed(Item item)
{
return (float)item.getAttributeModifiers(EquipmentSlot.MAINHAND)
.get(EntityAttributes.GENERIC_ATTACK_SPEED).stream().findFirst()

View File

@ -135,7 +135,6 @@
"description.wurst.hack.safewalk": "Zabraňuje pádu z hran.",
"description.wurst.hack.scaffoldwalk": "Automaticky umísťuje bloky pod nohy.",
"description.wurst.hack.search": "Pomáhá najít konkrétní bloky zvýrazněním jich barevně.",
"description.wurst.hack.servercrasher": "Vygeneruje položku, která dokáže shodit servery 1.15.x.\n§oPouze pro kreativní režim.§r",
"description.wurst.hack.skinderp": "Náhodně přepíná části postavy.",
"description.wurst.hack.sneak": "Neustálé plížení.",
"description.wurst.hack.snowshoe": "Umožňuje chůzi po prašanu.",

View File

@ -119,6 +119,7 @@
"description.wurst.hack.nolevitation": "Disables the levitation effect when you get hit by a Shulker.\n\n§c§lWARNING:§r You will fall if you activate this while the levitation effect is already active!",
"description.wurst.hack.nooverlay": "Blocks the overlays of water and lava.",
"description.wurst.hack.nopumpkin": "Blocks the overlay when wearing a pumpkin on your head.",
"description.wurst.hack.noshieldoverlay": "Lowers the shield so it covers less of your screen.",
"description.wurst.hack.noslowdown": "Cancels slowness effects caused by honey, soul sand and using items.",
"description.wurst.hack.noweather": "Allows you to alter the client-side weather, time and moon phase.",
"description.wurst.hack.noweb": "Prevents you from getting slowed down by cobwebs.",
@ -129,6 +130,7 @@
"description.wurst.hack.panic": "Instantly turns off all enabled hacks.\nBe careful with this one!",
"description.wurst.hack.parkour": "Makes you jump automatically when reaching the edge of a block.\nUseful for parkours and jump'n'runs.",
"description.wurst.hack.playeresp": "Highlights nearby players.\nESP boxes of friends will appear in blue.",
"description.wurst.hack.portalesp": "Highlights nearby portals.",
"description.wurst.hack.portalgui": "Allows you to open GUIs in portals.",
"description.wurst.hack.potionsaver": "Freezes all potion effects while you are standing still.",
"description.wurst.hack.prophuntesp": "Allows you to see fake blocks in Prophunt.\nMade for Mineplex Prophunt. Might not work on other servers.",
@ -141,7 +143,6 @@
"description.wurst.hack.safewalk": "Prevents you from falling off edges.",
"description.wurst.hack.scaffoldwalk": "Automatically places blocks below your feet.",
"description.wurst.hack.search": "Helps you to find specific blocks by highlighting them in rainbow color.",
"description.wurst.hack.servercrasher": "Generates an item that can crash 1.15.x servers.\n§oCreative mode only.§r",
"description.wurst.hack.skinderp": "Randomly toggles parts of your skin.",
"description.wurst.hack.sneak": "Makes you sneak automatically.",
"description.wurst.hack.snowshoe": "Allows you to walk on powder snow.",

View File

@ -132,7 +132,6 @@
"description.wurst.hack.safewalk": "Vous empêche de tomber des bords.",
"description.wurst.hack.scaffoldwalk": "Place automatiquement des blocs sous vos pieds.",
"description.wurst.hack.search": "Vous aide à trouver des blocs spécifiques en les mettant en évidence en couleur arc-en-ciel.",
"description.wurst.hack.servercrasher": "Génère un élément qui peut planter les serveurs 1.15.x.\n§oMode Créatif uniquement.§r",
"description.wurst.hack.skinderp": "Bascule aléatoirement des parties de votre skin.",
"description.wurst.hack.sneak": "Vous fait vous s'accroupir automatiquement.",
"description.wurst.hack.snowshoe": "Permet de marcher sur de la poudreuse.",

View File

@ -135,7 +135,6 @@
"description.wurst.hack.safewalk": "Ti impedisce di cadere dai bordi.",
"description.wurst.hack.scaffoldwalk": "Posiziona automaticamente i blocchi sotto i tuoi piedi.",
"description.wurst.hack.search": "Ti aiuta a trovare blocchi specifici evidenziandoli nel colore dell'arcobaleno.",
"description.wurst.hack.servercrasher": "Genera un elemento che fa crashare i server in 1.15.x.\n§oUtilizzabile solo in modalità creativà.§r",
"description.wurst.hack.skinderp": "Alterna casualmente parti della tua pelle.",
"description.wurst.hack.sneak": "Ti fa piegare automaticamente.",
"description.wurst.hack.snowshoe": "Consente di camminare su neve farinosa.",

View File

@ -140,7 +140,6 @@
"description.wurst.hack.safewalk": "ブロックの端からの落下を防ぐ。",
"description.wurst.hack.scaffoldwalk": "足元に自動でブロックを設置する。",
"description.wurst.hack.search": "特定のブロックを虹色でハイライト表示し、探しやすくする。",
"description.wurst.hack.servercrasher": "バージョン 1.15.* のサーバーをクラッシュさせることができるアイテムを生成する。\n§oクリエイティブモードのみ。§r",
"description.wurst.hack.skinderp": "スキンのパーツの表示/非表示をランダムに切り替える。",
"description.wurst.hack.sneak": "自動でしゃがむ。",
"description.wurst.hack.snowshoe": "粉雪ブロックの上を歩くことができるようになる。",

View File

@ -111,7 +111,6 @@
"description.wurst.hack.safewalk": "블럭끝에서 떨어지지 않게 해줍니다.",
"description.wurst.hack.scaffoldwalk": "자동으로 발 아래에 블록을 배치합니다.",
"description.wurst.hack.search": "무지개 색상으로 강조하여 특정 블록을 찾는 데 도움을 줍니다.",
"description.wurst.hack.servercrasher": "1.15.x 버전 서버를 충돌시킬 수 있는 아이템을 생성합니다.\n§o크리에이티브 모드 전용.§r",
"description.wurst.hack.skinderp": "스킨의 커버를 무작위로 on/off 합니다.",
"description.wurst.hack.sneak": "웅크리게 합니다.",
"description.wurst.hack.speedhack": "달리기와 점프로 할 때보다 약 2.5배 더 빠르게 달릴 수 있게 해줍니다.\n\n§6§l주의:§r NoCheat+ 버전 3.13.2에서 패치되었습니다. 이전 버전의 NoCheat+에서만 우회됩니다.\n서버의 NoCheat+ 버전을 확인하려면 §l/ncp version§r을 입력하세요.",

View File

@ -135,7 +135,6 @@
"description.wurst.hack.safewalk": "Zapobiega spadaniu z krawędzi.",
"description.wurst.hack.scaffoldwalk": "Automatycznie umieszcza bloki pod nogami.",
"description.wurst.hack.search": "Pomaga znaleźć konkretne bloki, podświetlając je kolorem tęczy.",
"description.wurst.hack.servercrasher": "Generuje przedmiot, który może zcrashować serwery 1.15.x.\n§oTylko tryb kreatywny.§r",
"description.wurst.hack.skinderp": "Losowo przełącza części twojego skina.",
"description.wurst.hack.sneak": "Sprawia, że automatycznie się skradasz.",
"description.wurst.hack.snowshoe": "Umożliwia chodzenie po sypkim śniegu.",

View File

@ -131,7 +131,6 @@
"description.wurst.hack.safewalk": "Te previne din a cadea de pe margini.",
"description.wurst.hack.scaffoldwalk": "Plaseaza block-uri automat sub tine.",
"description.wurst.hack.search": "Te ajuta sa gasesti block-uri specifice, conturandu-le in culoarea aleasa.",
"description.wurst.hack.servercrasher": "Genereaza un item care poate da crash la serverele de 1.15.x.\n§oFunctioneaza doar in Creativ.§r",
"description.wurst.hack.skinderp": "Porneste si opreste la intamplare parti diferite din skinul tau.",
"description.wurst.hack.sneak": "Te pune automat pe sneak.",
"description.wurst.hack.snowshoe": "Iti permite sa umbli pe powder snow.",

View File

@ -135,7 +135,6 @@
"description.wurst.hack.safewalk": "Не даёт вам упасть с края блоков.",
"description.wurst.hack.scaffoldwalk": "Автоматически ставит блоки под ноги.",
"description.wurst.hack.search": "Помогает найти заданные блоки подсвечивая их всеми цветами радуги.",
"description.wurst.hack.servercrasher": "Создает вещь которая может крашить свервера на версиях 1.15.x .\n§oРаботает только в креативе.§r",
"description.wurst.hack.skinderp": "Переключает видимость слоёв скина в случайном порядке.",
"description.wurst.hack.sneak": "Заставляет Вас автоматически приседать.",
"description.wurst.hack.snowshoe": "Позволяет ходить по рыхлому снегу.",

View File

@ -131,7 +131,6 @@
"description.wurst.hack.safewalk": "Не дає вам впасти із краю блока.",
"description.wurst.hack.scaffoldwalk": "Автоматично ставить блоки під ноги.",
"description.wurst.hack.search": "Допомагає знайти задані блоки, підсвічуючи їх усіма кольорами веселки.",
"description.wurst.hack.servercrasher": "Створює річ, яка може крашити сервер на версії 1.15.x.\n§oПрацює тільки в креативі.§r",
"description.wurst.hack.skinderp": "Перемикає видимість шарів скіну у випадковому порядку.",
"description.wurst.hack.sneak": "Примушує вас автоматично присідати.",
"description.wurst.hack.snowshoe": "Дозволяє ходити по пухкому снігу.",

View File

@ -136,7 +136,6 @@
"description.wurst.hack.safewalk": "防止你从方块边缘摔落。",
"description.wurst.hack.scaffoldwalk": "自动在你的脚下搭方块。",
"description.wurst.hack.search": "帮助你找到所需要的方块并以彩虹色的方式高亮。",
"description.wurst.hack.servercrasher": "生成一个可以崩掉 1.15.x 服务器的物品。\n§o需要创造模式。§r",
"description.wurst.hack.skinderp": "随机切换你的皮肤。",
"description.wurst.hack.sneak": "让你自动保持潜行行走。",
"description.wurst.hack.snowshoe": "允许你在细雪上行走。",

View File

@ -129,7 +129,6 @@
"description.wurst.hack.safewalk": "防止你從方塊邊緣跌落嚟。",
"description.wurst.hack.scaffoldwalk": "自動喺你嘅腳下搭方塊。",
"description.wurst.hack.search": "幫助你搵到所需要嘅方塊並以彩虹色嘅方式高亮。",
"description.wurst.hack.servercrasher": "生成一個物品可以崩潰 1.15.x 嘅伺服器。\n§o僅限創造模式§r。",
"description.wurst.hack.skinderp": "隨機切換你嘅皮膚。",
"description.wurst.hack.sneak": "讓你自動保持潛行行走。",
"description.wurst.hack.snowshoe": "可以讓你喺細雪上行走。",

View File

@ -135,7 +135,6 @@
"description.wurst.hack.safewalk": "防止你從方塊邊緣掉出。",
"description.wurst.hack.scaffoldwalk": "自動在你的脚下搭方塊。",
"description.wurst.hack.search": "幫助你找到所需要的方塊並以彩虹色的管道高亮。",
"description.wurst.hack.servercrasher": "生成一個物品可以崩掉1.15.x的服務器。\n§o僅限創造模式§r。",
"description.wurst.hack.skinderp": "隨機切換你的皮膚。",
"description.wurst.hack.sneak": "讓你自動保持潜行行走。",
"description.wurst.hack.snowshoe": "可以讓你在細雪上行走。",

View File

@ -29,7 +29,7 @@
"accessWidener" : "wurst.accesswidener",
"depends": {
"fabricloader": ">=0.14.19",
"fabricloader": ">=0.15.0",
"fabric-api": ">=0.81.2",
"minecraft": "~1.20-beta.2",
"java": ">=17"
@ -39,7 +39,8 @@
},
"breaks": {
"wi_zoom": "*",
"wi-zoom": "*"
"wi-zoom": "*",
"vulkanmod": "*"
},
"custom": {
"modmenu": {

View File

@ -36,6 +36,7 @@
"GameMenuScreenMixin",
"GameRendererMixin",
"GenericContainerScreenMixin",
"HeldItemRendererMixin",
"IngameHudMixin",
"InGameOverlayRendererMixin",
"KeyBindingMixin",