Update to 1.21.3/1.21.4 (#399)
* Update to 1.21.3 part 1 Don't expect it to work anytime soon. * Update to 1.21.3 part 2 * Gradle 8.8 -> 8.12 * Working Build 1.21.3 Had to revert gradle to 8.10 due to unforseen issues. * Removed Unused Imports * Small rendering fixes (hopefully) * 1.21.4 port * Use Utils.canUpdate in AutoCraft * Intellij code fixes --------- Co-authored-by: crazymoose77756 <ryanrogo064@gmail.com> Co-authored-by: SByte <stormybytes@gmail.com>
This commit is contained in:
@@ -5,6 +5,7 @@ import meteordevelopment.meteorclient.systems.modules.Modules;
|
||||
|
||||
import net.minecraft.client.gl.PostEffectProcessor;
|
||||
import net.minecraft.client.render.RenderTickCounter;
|
||||
import net.minecraft.client.util.Pool;
|
||||
import org.spongepowered.asm.mixin.Final;
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.Shadow;
|
||||
@@ -18,6 +19,8 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
||||
@Mixin(GameRenderer.class)
|
||||
public class GameRendererMixin {
|
||||
@Shadow @Final MinecraftClient client;
|
||||
@Shadow @Final
|
||||
Pool pool;
|
||||
|
||||
@Inject(method = "render", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/render/WorldRenderer;drawEntityOutlinesFramebuffer()V", ordinal = 0))
|
||||
private void renderShader(RenderTickCounter tickCounter, boolean tick, CallbackInfo ci) {
|
||||
@@ -26,8 +29,8 @@ public class GameRendererMixin {
|
||||
PostEffectProcessor shader = renderingModule.getShaderEffect();
|
||||
|
||||
if (shader != null) {
|
||||
shader.setupDimensions(client.getWindow().getFramebufferWidth(), client.getWindow().getFramebufferHeight());
|
||||
shader.render(tickCounter.getTickDelta(tick));
|
||||
// shader.setupDimensions(client.getWindow().getFramebufferWidth(), client.getWindow().getFramebufferHeight());
|
||||
shader.render(this.client.getFramebuffer(), this.pool);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,9 +5,11 @@ import meteordevelopment.meteorclient.systems.modules.Modules;
|
||||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
import net.minecraft.client.render.entity.LivingEntityRenderer;
|
||||
import net.minecraft.client.render.entity.model.EntityModel;
|
||||
import net.minecraft.client.render.entity.state.LivingEntityRenderState;
|
||||
import net.minecraft.client.render.entity.state.PlayerEntityRenderState;
|
||||
import net.minecraft.client.util.math.MatrixStack;
|
||||
import net.minecraft.entity.LivingEntity;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.util.math.RotationAxis;
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.injection.At;
|
||||
@@ -16,14 +18,14 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
@Mixin(LivingEntityRenderer.class)
|
||||
public class LivingEntityRendererMixin<T extends LivingEntity> {
|
||||
public class LivingEntityRendererMixin<T extends LivingEntity, S extends LivingEntityRenderState, M extends EntityModel<? super S>> {
|
||||
|
||||
@Inject(method = "setupTransforms", at = @At(value = "TAIL"))
|
||||
private void dinnerboneEntities(T entity, MatrixStack matrices, float animationProgress, float bodyYaw, float tickDelta, float scale, CallbackInfo ci) {
|
||||
private void dinnerboneEntities(S state, MatrixStack matrices, float animationProgress, float bodyYaw, CallbackInfo ci) {
|
||||
Rendering renderingModule = Modules.get().get(Rendering.class);
|
||||
if (renderingModule == null) return;
|
||||
if ((!(entity instanceof PlayerEntity)) && renderingModule.dinnerboneEnabled()) {
|
||||
matrices.translate(0.0D, entity.getHeight() + 0.1F, 0.0D);
|
||||
if ((!(state instanceof PlayerEntityRenderState)) && renderingModule.dinnerboneEnabled()) {
|
||||
matrices.translate(0.0D, state.height + 0.1F, 0.0D);
|
||||
matrices.multiply(RotationAxis.POSITIVE_Z.rotationDegrees(180.0F));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,17 +1,18 @@
|
||||
package anticope.rejects.mixin;
|
||||
|
||||
import net.minecraft.network.packet.c2s.play.VehicleMoveC2SPacket;
|
||||
import net.minecraft.util.math.Vec3d;
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.Mutable;
|
||||
import org.spongepowered.asm.mixin.gen.Accessor;
|
||||
import org.spongepowered.asm.mixin.gen.Invoker;
|
||||
|
||||
@Mixin(VehicleMoveC2SPacket.class)
|
||||
public interface VehicleMoveC2SPacketAccessor {
|
||||
@Mutable
|
||||
@Accessor("x")
|
||||
void setX(double x);
|
||||
@Accessor("position")
|
||||
Vec3d getPosition();
|
||||
|
||||
@Mutable
|
||||
@Accessor("z")
|
||||
void setZ(double z);
|
||||
@Invoker("<init>")
|
||||
static VehicleMoveC2SPacket create(Vec3d position, float yaw, float pitch, boolean onGround) {
|
||||
throw new AssertionError();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,8 +17,8 @@ public class ModuleMixin {
|
||||
@Mutable @Shadow public String name;
|
||||
|
||||
@Mutable @Shadow public String title;
|
||||
|
||||
@Inject(method = "<init>", at = @At("TAIL"))
|
||||
|
||||
@Inject(method = "<init>*", at = @At("TAIL"))
|
||||
private void onInit(Category category, String name, String description, String[] aliases, CallbackInfo info) {
|
||||
if (RejectsConfig.get().duplicateModuleNames) {
|
||||
this.name = RejectsUtils.getModuleName(name);
|
||||
|
||||
Reference in New Issue
Block a user