Skip to content
This repository was archived by the owner on Nov 28, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
46 commits
Select commit Hold shift + click to select a range
6ef2c56
port https://github.com/Sol-Client/client/pull/136
moehreag Jun 30, 2023
d68d9ba
Merge branch 'multiversion' into feat/sol/darkkronicle-bedwars-display
moehreag Jul 1, 2023
dad74df
Merge branch 'multiversion' into feat/sol/darkkronicle-bedwars-display
moehreag Jul 1, 2023
dd59b2b
remove unnecessary old code
moehreag Jul 4, 2023
dc941de
move class
moehreag Jul 4, 2023
0ca8f50
restore functionality
moehreag Jul 6, 2023
d28ced6
apply license header
moehreag Jul 6, 2023
1307e1e
fix some bugs, add translations
moehreag Jul 7, 2023
f3f14f3
fully migrate to new Event system
moehreag Jul 8, 2023
94efe3f
port to the other versions
moehreag Jul 8, 2023
f8cd917
remove timings code, fix some mixins
moehreag Jul 8, 2023
a27d3c0
Merge branch 'multiversion' into feat/sol/darkkronicle-bedwars-display
moehreag Jul 8, 2023
0ec51df
oversaw this
moehreag Jul 8, 2023
e7ef3d2
fix more bugs
moehreag Jul 8, 2023
b910240
add more customisation options
moehreag Jul 9, 2023
f46dace
format a lot of things
moehreag Jul 9, 2023
c347e59
add customisable death messages
moehreag Jul 10, 2023
8e2609e
add credits
moehreag Jul 10, 2023
169814d
fix a bug, add option to usually hide the hud
moehreag Jul 10, 2023
1f15b11
re-use original footer
moehreag Jul 11, 2023
acf0abb
use vanilla textures instead of custom ones
moehreag Jul 11, 2023
035b404
update credits to reflect the latest changes
moehreag Jul 11, 2023
42fd44c
oversight
moehreag Jul 12, 2023
df47dc4
fix a potential crash
moehreag Jul 12, 2023
2608f97
remove unnecessary darkening of the disabled furnace
moehreag Jul 12, 2023
954fb9a
fix typo + PlayerHud scaling
moehreag Jul 12, 2023
944c51d
add option to remove vignette, fix more things
moehreag Jul 12, 2023
46a1e71
apply sky fix on other versions as well
moehreag Jul 12, 2023
2a9ede4
another spotted error + missing translation key
moehreag Jul 12, 2023
73bc7f4
suggested changes by DarkKronicle
moehreag Jul 12, 2023
7ecaef9
mixin fixes + remove unused methods
moehreag Jul 12, 2023
45a0145
change bottom bar
moehreag Jul 13, 2023
5889424
address changes requested by TheKodeToad
moehreag Jul 14, 2023
2544fcd
fix 1.19.4 mixin
moehreag Jul 14, 2023
f504db4
bump version and add changelog
moehreag Jul 14, 2023
f56c622
remove code duplication
moehreag Jul 14, 2023
664b0c9
fix the ArmorHUD on 1.20
moehreag Jul 14, 2023
a5b6cd6
update config version to fix a bug
moehreag Jul 14, 2023
d5acde9
address suggestions from DarkKronicle
moehreag Jul 15, 2023
6ae663b
Merge branch 'multiversion' into feat/sol/darkkronicle-bedwars-display
moehreag Jul 15, 2023
d2870a8
remove Lucky Block Bedwars from start triggers
moehreag Jul 15, 2023
8dcdc98
fix last killer display
moehreag Jul 15, 2023
3bc62ae
fix a mixin on 1.16 versions
moehreag Jul 15, 2023
5439dab
add random stat generation
moehreag Jul 16, 2023
a9bdb36
clamp randomly generated stats
moehreag Jul 16, 2023
c1ab549
Merge branch 'multiversion' into feat/sol/darkkronicle-bedwars-display
moehreag Jul 16, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ public class AxolotlClientConfig extends ConfigHolder {
public final BooleanOption timeChangerEnabled = new BooleanOption("enabled", false);
public final IntegerOption customTime = new IntegerOption("time", 0, 0, 24000);
public final BooleanOption customSky = new BooleanOption("customSky", true);
public final BooleanOption showSunMoon = new BooleanOption("showSunMoon", true);
public final BooleanOption dynamicFOV = new BooleanOption("dynamicFov", true);
public final BooleanOption fullBright = new BooleanOption("fullBright", false);
public final BooleanOption removeVignette = new BooleanOption("removeVignette", false);
public final BooleanOption lowFire = new BooleanOption("lowFire", false);
public final BooleanOption lowShield = new BooleanOption("lowShield", false);
public final ColorOption hitColor = new ColorOption("hitColor",
Expand Down Expand Up @@ -176,10 +176,10 @@ public void init() {
general.addSubCategory(searchFilters);

rendering.add(customSky,
showSunMoon,
AxolotlClientConfigConfig.chromaSpeed,
dynamicFOV,
fullBright,
removeVignette,
lowFire,
lowShield,
hitColor,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,11 +167,11 @@ private void initCredits() {
credits.add(new Credit("YakisikliBaran", "Turkish Translation"));
credits.add(new Credit("TheKodeToad", "Contributor", "Motion Blur", "Freelook", "Zoom"));
credits.add(new Credit("DragonEggBedrockBreaking", "Bugfixing", "Inspiration of new Features"));
credits.add(new Credit("DarkKronicle", "Bedwars Overlay", "Author of KronHUD, the best HUD mod!"));

credits.add(new SpacerTitle("- - - - - - " + I18n.translate("other_people") + " - - - - - -"));

credits.add(new Credit("gart", "gartbin dev and host", "Image sharing help", "https://gart.sh"));
credits.add(new Credit("DarkKronicle", "Author of KronHUD, the best HUD mod!"));
credits.add(new Credit("AMereBagatelle", "Author of the excellent FabricSkyBoxes Mod"));

if (!externalModuleCredits.isEmpty()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,31 +22,40 @@

package io.github.axolotlclient.mixin;

import io.github.axolotlclient.modules.hypixel.autoboop.AutoBoop;
import io.github.axolotlclient.modules.hypixel.autogg.AutoGG;
import io.github.axolotlclient.modules.hypixel.autotip.AutoTip;
import io.github.axolotlclient.modules.hypixel.nickhider.NickHider;
import io.github.axolotlclient.util.events.Events;
import io.github.axolotlclient.util.events.impl.ReceiveChatMessageEvent;
import net.minecraft.client.gui.hud.ChatHud;
import net.minecraft.text.Text;
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.ModifyArg;
import org.spongepowered.asm.mixin.injection.ModifyVariable;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;

@Mixin(ChatHud.class)
public abstract class ChatHudMixin {

@Inject(method = "addMessage(Lnet/minecraft/text/Text;)V", at = @At("HEAD"), cancellable = true)
public void axolotlclient$autoThings(Text message, CallbackInfo ci) {
AutoGG.getInstance().onMessage(message);
AutoBoop.getInstance().onMessage(message);

if (AutoTip.getInstance().onChatMessage(message)) {
@Inject(method = "addMessage(Lnet/minecraft/text/Text;I)V", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/hud/ChatHud;addMessage(Lnet/minecraft/text/Text;IIZ)V"), cancellable = true)
public void axolotlclient$autoThings(Text message, int messageId, CallbackInfo ci) {
if (message == null) {
ci.cancel();
}
}

@ModifyVariable(method = "addMessage(Lnet/minecraft/text/Text;I)V", at = @At("HEAD"), argsOnly = true)
private Text axolotlclient$onChatMessage(Text message) {
ReceiveChatMessageEvent event = new ReceiveChatMessageEvent(false, message.getString(), message);
Events.RECEIVE_CHAT_MESSAGE_EVENT.invoker().invoke(event);
if (event.isCancelled()) {
return null;
} else if (event.getNewMessage() != null) {
return event.getNewMessage();
}
return message;
}

@ModifyArg(method = "addMessage(Lnet/minecraft/text/Text;)V", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/hud/ChatHud;addMessage(Lnet/minecraft/text/Text;I)V"), index = 0)
public Text axolotlclient$editChat(Text message) {
return NickHider.getInstance().editMessage(message);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@

import io.github.axolotlclient.modules.freelook.Freelook;
import io.github.axolotlclient.modules.hypixel.skyblock.Skyblock;
import io.github.axolotlclient.util.Hooks;
import io.github.axolotlclient.util.events.Events;
import io.github.axolotlclient.util.events.impl.PlayerDirectionChangeEvent;
import net.minecraft.entity.Entity;
import net.minecraft.util.math.MathHelper;
import org.spongepowered.asm.mixin.Mixin;
Expand Down Expand Up @@ -54,7 +55,7 @@ public abstract class EntityMixin {
float pitch = prevPitch + (float) (mouseDeltaY * .15);
float yaw = prevYaw + (float) (mouseDeltaX * .15);
pitch = MathHelper.clamp(pitch, -90.0F, 90.0F);
Hooks.PLAYER_DIRECTION_CHANGE.invoker().onChange(prevPitch, prevYaw, pitch, yaw);
Events.PLAYER_DIRECTION_CHANGE.invoker().invoke(new PlayerDirectionChangeEvent(prevPitch, prevYaw, pitch, yaw));
}

@Shadow
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@

import io.github.axolotlclient.AxolotlClient;
import io.github.axolotlclient.modules.hypixel.HypixelAbstractionLayer;
import io.github.axolotlclient.modules.hypixel.bedwars.BedwarsMod;
import io.github.axolotlclient.modules.hypixel.levelhead.LevelHead;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.font.TextRenderer;
Expand Down Expand Up @@ -69,10 +70,24 @@ public abstract class EntityRendererMixin<T extends Entity> {
CallbackInfo ci) {
if (entity instanceof AbstractClientPlayerEntity) {
if (MinecraftClient.getInstance().getCurrentServerEntry() != null
&& MinecraftClient.getInstance().getCurrentServerEntry().address.contains("hypixel.net")) {
if (HypixelAbstractionLayer.hasValidAPIKey() && LevelHead.getInstance().enabled.get()
&& string.getString().contains(entity.getName().getString())) {
TextRenderer textRenderer = MinecraftClient.getInstance().textRenderer;
&& MinecraftClient.getInstance().getCurrentServerEntry().address.contains("hypixel.net")
&& string.getString().contains(entity.getName().getString())) {
TextRenderer textRenderer = MinecraftClient.getInstance().textRenderer;
if (BedwarsMod.getInstance().isEnabled() &&
BedwarsMod.getInstance().inGame() &&
BedwarsMod.getInstance().bedwarsLevelHead.get()) {
String text = BedwarsMod.getInstance().getGame().get().getLevelHead((AbstractClientPlayerEntity) entity);
if (text != null) {
float x = -textRenderer.getWidth(text) / 2F;
float y = string.getString().contains("deadmau5") ? -20 : -10;

Matrix4f matrix4f = matrices.peek().getModel();
MinecraftClient.getInstance().textRenderer.draw(text, x, y,
LevelHead.getInstance().textColor.get().getAsInt(), AxolotlClient.CONFIG.useShadows.get(),
matrix4f, vertexConsumers, false, LevelHead.getInstance().background.get() ? 127 : 0,
light);
}
} else if (HypixelAbstractionLayer.hasValidAPIKey() && LevelHead.getInstance().enabled.get()) {
String text = "Level: " + HypixelAbstractionLayer.getPlayerLevel(String.valueOf(entity.getUuid()), LevelHead.getInstance().mode.get());

float x = -textRenderer.getWidth(text) / 2F;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,26 +22,28 @@

package io.github.axolotlclient.mixin;

import io.github.axolotlclient.AxolotlClient;
import io.github.axolotlclient.modules.hud.HudManager;
import io.github.axolotlclient.modules.hud.gui.hud.PotionsHud;
import io.github.axolotlclient.modules.hud.gui.hud.vanilla.ActionBarHud;
import io.github.axolotlclient.modules.hud.gui.hud.vanilla.CrosshairHud;
import io.github.axolotlclient.modules.hud.gui.hud.vanilla.HotbarHUD;
import io.github.axolotlclient.modules.hud.gui.hud.vanilla.ScoreboardHud;
import io.github.axolotlclient.modules.hypixel.bedwars.BedwarsMod;
import io.github.axolotlclient.util.events.Events;
import io.github.axolotlclient.util.events.impl.ScoreboardRenderEvent;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.font.TextRenderer;
import net.minecraft.client.gui.hud.InGameHud;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.entity.Entity;
import net.minecraft.scoreboard.ScoreboardObjective;
import net.minecraft.text.StringVisitable;
import net.minecraft.text.Text;
import org.jetbrains.annotations.Nullable;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.Shadow;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.ModifyArgs;
import org.spongepowered.asm.mixin.injection.Redirect;
import org.spongepowered.asm.mixin.injection.*;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
import org.spongepowered.asm.mixin.injection.invoke.arg.Args;

Expand Down Expand Up @@ -89,7 +91,9 @@ public abstract class InGameHudMixin {
@Inject(method = "renderScoreboardSidebar", at = @At("HEAD"), cancellable = true)
public void axolotlclient$renderScoreboard(MatrixStack matrices, ScoreboardObjective objective, CallbackInfo ci) {
ScoreboardHud hud = (ScoreboardHud) HudManager.getInstance().get(ScoreboardHud.ID);
if (hud != null && hud.isEnabled()) {
ScoreboardRenderEvent event = new ScoreboardRenderEvent(objective);
Events.SCOREBOARD_RENDER_EVENT.invoker().invoke(event);
if (event.isCancelled() || hud.isEnabled()) {
ci.cancel();
}
}
Expand Down Expand Up @@ -187,4 +191,40 @@ public abstract class InGameHudMixin {
}
return scaledWidth;
}

@ModifyVariable(
method = "renderStatusBars",
at = @At(
value = "STORE"
),
ordinal = 18
)
public int axolotlclient$displayHardcoreHearts(int offset) {
boolean hardcore = BedwarsMod.getInstance().isEnabled() &&
BedwarsMod.getInstance().inGame() && BedwarsMod.getInstance().hardcoreHearts.get() &&
!BedwarsMod.getInstance().getGame().get().getSelf().isBed();
return hardcore ? 5 : offset;
}

@ModifyVariable(
method = "renderStatusBars",
at = @At(
value = "STORE"
), ordinal = 20
)
public int axolotlclient$dontHunger(int heartCount) {
if (heartCount == 0 && BedwarsMod.getInstance().isEnabled() &&
BedwarsMod.getInstance().inGame() &&
!BedwarsMod.getInstance().showHunger.get()) {
return 3;
}
return heartCount;
}

@Inject(method = "renderVignetteOverlay", at = @At("HEAD"), cancellable = true)
private void axolotlclient$removeVignette(Entity entity, CallbackInfo ci){
if(AxolotlClient.CONFIG.removeVignette.get()){
ci.cancel();
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@

package io.github.axolotlclient.mixin;

import io.github.axolotlclient.util.Hooks;
import io.github.axolotlclient.util.events.Events;
import io.github.axolotlclient.util.events.impl.KeyBindChangeEvent;
import io.github.axolotlclient.util.events.impl.KeyPressEvent;
import net.minecraft.client.option.KeyBinding;
import net.minecraft.client.util.InputUtil;
import org.spongepowered.asm.mixin.Mixin;
Expand All @@ -35,13 +37,13 @@ public abstract class KeyBindMixin {

@Inject(method = "setBoundKey", at = @At("RETURN"))
public void axolotlclient$boundKeySet(InputUtil.Key key, CallbackInfo ci) {
Hooks.KEYBIND_CHANGE.invoker().setBoundKey(key);
Events.KEYBIND_CHANGE.invoker().invoke(new KeyBindChangeEvent(key));
}

@Inject(method = "setPressed", at = @At("RETURN"))
public void axolotlclient$onPress(boolean pressed, CallbackInfo ci) {
if (pressed) {
Hooks.KEYBIND_PRESS.invoker().onPress((KeyBinding) ((Object) this));
Events.KEY_PRESS.invoker().invoke(new KeyPressEvent((KeyBinding) ((Object) this)));
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,14 @@
import io.github.axolotlclient.modules.blur.MenuBlur;
import io.github.axolotlclient.modules.rpc.DiscordRPC;
import io.github.axolotlclient.util.NetworkHelper;
import io.github.axolotlclient.util.events.Events;
import io.github.axolotlclient.util.events.impl.WorldLoadEvent;
import net.fabricmc.loader.api.FabricLoader;
import net.minecraft.SharedConstants;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.RunArgs;
import net.minecraft.client.gui.screen.Screen;
import net.minecraft.client.world.ClientWorld;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Inject;
Expand Down Expand Up @@ -83,4 +86,9 @@ public abstract class MinecraftClientMixin {
private void axolotlclient$noModdedSigns(CallbackInfoReturnable<Boolean> cir) {
cir.setReturnValue(false);
}

@Inject(method = "joinWorld", at = @At("HEAD"))
private void axolotlclient$onWorldLoad(ClientWorld world, CallbackInfo ci) {
Events.WORLD_LOAD_EVENT.invoker().invoke(new WorldLoadEvent(world));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@
import io.github.axolotlclient.modules.hud.HudManager;
import io.github.axolotlclient.modules.scrollableTooltips.ScrollableTooltips;
import io.github.axolotlclient.modules.zoom.Zoom;
import io.github.axolotlclient.util.Hooks;
import io.github.axolotlclient.util.events.Events;
import io.github.axolotlclient.util.events.impl.MouseInputEvent;
import net.minecraft.client.Mouse;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
Expand All @@ -39,7 +40,7 @@ public abstract class MouseMixin {
@Inject(method = "onMouseButton", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/option/KeyBinding;setKeyPressed(Lnet/minecraft/client/util/InputUtil$Key;Z)V"))
private void axolotlclient$onMouseButton(long window, int button, int action, int mods, CallbackInfo ci) {
if (action == 1) {
Hooks.MOUSE_INPUT.invoker().onMouseButton(window, button, action, mods);
Events.MOUSE_INPUT.invoker().invoke(new MouseInputEvent(window, button, action, mods));
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,12 @@
import io.github.axolotlclient.modules.hud.HudManager;
import io.github.axolotlclient.modules.hud.gui.hud.simple.ComboHud;
import io.github.axolotlclient.modules.hud.gui.hud.simple.ReachHud;
import io.github.axolotlclient.modules.hypixel.bedwars.BedwarsMod;
import io.github.axolotlclient.modules.particles.Particles;
import net.minecraft.client.MinecraftClient;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityType;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.damage.DamageSource;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.particle.ParticleTypes;
Expand All @@ -40,9 +42,9 @@
import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable;

@Mixin(PlayerEntity.class)
public abstract class PlayerEntityMixin extends Entity {
public abstract class PlayerEntityMixin extends LivingEntity {

public PlayerEntityMixin(EntityType<?> entityType, World world) {
protected PlayerEntityMixin(EntityType<? extends LivingEntity> entityType, World world) {
super(entityType, world);
}

Expand Down Expand Up @@ -84,4 +86,12 @@ public PlayerEntityMixin(EntityType<?> entityType, World world) {
comboHud.onEntityDamage(this);
}
}

@Override
public int getArmor() {
if (BedwarsMod.getInstance().isEnabled() && BedwarsMod.getInstance().inGame() && !BedwarsMod.getInstance().displayArmor.get()) {
return 0;
}
return super.getArmor();
}
}
Loading