Skip to content

Commit

Permalink
Updated to 1.21.4
Browse files Browse the repository at this point in the history
  • Loading branch information
coltonk9043 committed Dec 9, 2024
1 parent cb0342d commit 72128ed
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 26 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ dependencies {
modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}"

modImplementation("maven.modrinth:sodium:${project.sodium_version}")
modImplementation files("libs/baritone-standalone-fabric-1.11.1.jar")
modImplementation files("libs/baritone-standalone-fabric-1.13.0.jar")
implementation "dev.babbaj:nether-pathfinder:1.4.1"

libImpl("io.netty:netty-handler-proxy:${project.netty_version}") { transitive = false }
Expand Down
12 changes: 6 additions & 6 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ org.gradle.parallel=true

# Fabric Properties
# check these on https://fabricmc.net/develop
minecraft_version=1.21.3
yarn_mappings=1.21.3+build.2
minecraft_version=1.21.4
yarn_mappings=1.21.4+build.1
loader_version=0.16.9

# Mod Properties
Expand All @@ -14,14 +14,14 @@ maven_group=net.aoba
archives_base_name=Aoba

# Dependencies
fabric_version=0.110.0+1.21.3
fabric_version=0.111.0+1.21.4
netty_version=4.1.112.Final

# Sodium (https://github.com/CaffeineMC/sodium-fabric)
sodium_version=mc1.21.3-0.6.0-fabric
sodium_version=mc1.21.4-0.6.3-fabric

# Lithium (https://github.com/CaffeineMC/lithium-fabric)
lithium_version=mc1.21.3-0.14.2
lithium_version=mc1.21.4-0.14.4

# Iris (https://github.com/IrisShaders/Iris)
iris_version=1.8.0+1.21.3-fabric
iris_version=1.8.3+1.21.4-fabric
Binary file not shown.
5 changes: 3 additions & 2 deletions src/main/java/net/aoba/mixin/HandledScreenMixin.java
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,9 @@ public boolean renderShulkerToolTip(DrawContext context, int offsetX, int offset
Item focusedItem = stack.getItem();
if (focusedItem instanceof BlockItem bi && bi.getBlock() instanceof ShulkerBoxBlock) {
try {
Color c = new Color(
Objects.requireNonNull(ShulkerBoxBlock.getColor(stack.getItem())).getEntityColor());
ShulkerBoxBlock shulkerBoxBlock = (ShulkerBoxBlock) bi.getBlock();

Color c = new Color(Objects.requireNonNull(shulkerBoxBlock.getColor()).getEntityColor());
colors = new float[] { c.getRed() / 255f, c.getGreen() / 255f, c.getRed() / 255f,
c.getAlpha() / 255f };
} catch (NullPointerException npe) {
Expand Down
6 changes: 3 additions & 3 deletions src/main/java/net/aoba/mixin/InGameOverlayRendererMixin.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@

import net.aoba.Aoba;
import net.aoba.module.modules.render.NoRender;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.gui.hud.InGameOverlayRenderer;
import net.minecraft.client.render.VertexConsumerProvider;
import net.minecraft.client.util.math.MatrixStack;

@Mixin(InGameOverlayRenderer.class)
public abstract class InGameOverlayRendererMixin {
@Inject(method = "renderFireOverlay", at = @At("HEAD"), cancellable = true)
private static void onRenderFireOverlay(MinecraftClient minecraftClient, MatrixStack matrixStack,
@Inject(method = "renderFireOverlay(Lnet/minecraft/client/util/math/MatrixStack;Lnet/minecraft/client/render/VertexConsumerProvider;)V", at = @At("HEAD"), cancellable = true)
private static void onRenderFireOverlay(MatrixStack matrices, VertexConsumerProvider vertexConsumers,
CallbackInfo info) {
NoRender norender = (NoRender) Aoba.getInstance().moduleManager.norender;

Expand Down
7 changes: 3 additions & 4 deletions src/main/java/net/aoba/mixin/WorldRendererMixin.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
import net.minecraft.client.render.Camera;
import net.minecraft.client.render.Frustum;
import net.minecraft.client.render.GameRenderer;
import net.minecraft.client.render.LightmapTextureManager;
import net.minecraft.client.render.RenderTickCounter;
import net.minecraft.client.render.VertexConsumer;
import net.minecraft.client.render.WorldRenderer;
Expand All @@ -48,10 +47,10 @@ public class WorldRendererMixin {
@Shadow
private Frustum frustum;

@Inject(at = @At("TAIL"), method = "render(Lnet/minecraft/client/util/ObjectAllocator;Lnet/minecraft/client/render/RenderTickCounter;ZLnet/minecraft/client/render/Camera;Lnet/minecraft/client/render/GameRenderer;Lnet/minecraft/client/render/LightmapTextureManager;Lorg/joml/Matrix4f;Lorg/joml/Matrix4f;)V", cancellable = false)
@Inject(at = @At("TAIL"), method = "render(Lnet/minecraft/client/util/ObjectAllocator;Lnet/minecraft/client/render/RenderTickCounter;ZLnet/minecraft/client/render/Camera;Lnet/minecraft/client/render/GameRenderer;Lorg/joml/Matrix4f;Lorg/joml/Matrix4f;)V", cancellable = false)
public void render(ObjectAllocator allocator, RenderTickCounter tickCounter, boolean renderBlockOutline,
Camera camera, GameRenderer gameRenderer, LightmapTextureManager lightmapTextureManager,
Matrix4f positionMatrix, Matrix4f projectionMatrix, CallbackInfo ci) {
Camera camera, GameRenderer gameRenderer, Matrix4f positionMatrix, Matrix4f projectionMatrix,
CallbackInfo ci) {
if (Aoba.getInstance().moduleManager != null) {
GL11.glEnable(GL11.GL_BLEND);
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
Expand Down
10 changes: 0 additions & 10 deletions src/main/java/net/aoba/utils/render/Render2D.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,9 @@
import net.minecraft.client.gui.DrawContext;
import net.minecraft.client.render.BufferBuilder;
import net.minecraft.client.render.BufferRenderer;
import net.minecraft.client.render.DiffuseLighting;
import net.minecraft.client.render.Tessellator;
import net.minecraft.client.render.VertexFormat;
import net.minecraft.client.render.VertexFormats;
import net.minecraft.client.render.model.BakedModel;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.item.ItemStack;
import net.minecraft.util.Identifier;
Expand Down Expand Up @@ -702,15 +700,7 @@ public static void drawVerticalGradient(Matrix4f matrix4f, float x, float y, flo
*/
public static void drawItem(DrawContext drawContext, ItemStack stack, float x, float y) {
MinecraftClient MC = MinecraftClient.getInstance();
BakedModel bakedModel = MC.getItemRenderer().getModel(stack, null, null, 0);
boolean sidelit = bakedModel.isSideLit();
if (!sidelit) {
DiffuseLighting.disableGuiDepthLighting();
}
drawContext.drawItem(stack, (int) x, (int) y);
if (!sidelit) {
DiffuseLighting.enableGuiDepthLighting();
}
}

/**
Expand Down

0 comments on commit 72128ed

Please sign in to comment.