From 89a64a375ec1bb00fefd6841a935c09bd3c6973e Mon Sep 17 00:00:00 2001 From: Howard Stark Date: Sat, 4 Aug 2018 21:27:34 -0400 Subject: [PATCH] Add EntityRenderer renderWorldPass injection --- .../java/baritone/bot/RenderPassHandler.java | 4 ++++ .../bot/pathing/movement/IMovement.java | 13 ---------- .../launch/mixins/MixinEntityRenderer.java | 24 +++++++++++++++++++ 3 files changed, 28 insertions(+), 13 deletions(-) create mode 100644 src/main/java/baritone/bot/RenderPassHandler.java delete mode 100644 src/main/java/baritone/bot/pathing/movement/IMovement.java create mode 100644 src/main/java/baritone/launch/mixins/MixinEntityRenderer.java diff --git a/src/main/java/baritone/bot/RenderPassHandler.java b/src/main/java/baritone/bot/RenderPassHandler.java new file mode 100644 index 00000000..864567ec --- /dev/null +++ b/src/main/java/baritone/bot/RenderPassHandler.java @@ -0,0 +1,4 @@ +package baritone.bot; + +public class RenderPassHandler { +} diff --git a/src/main/java/baritone/bot/pathing/movement/IMovement.java b/src/main/java/baritone/bot/pathing/movement/IMovement.java deleted file mode 100644 index 7ab38c0c..00000000 --- a/src/main/java/baritone/bot/pathing/movement/IMovement.java +++ /dev/null @@ -1,13 +0,0 @@ -package baritone.bot.pathing.movement; - -public interface IMovement { - - /** - * Handles the execution of the latest Movement - * State, and offers a Status to the calling class. - * - * @return Status - */ - MovementState.MovementStatus update(); - -} diff --git a/src/main/java/baritone/launch/mixins/MixinEntityRenderer.java b/src/main/java/baritone/launch/mixins/MixinEntityRenderer.java new file mode 100644 index 00000000..2e079996 --- /dev/null +++ b/src/main/java/baritone/launch/mixins/MixinEntityRenderer.java @@ -0,0 +1,24 @@ +package baritone.launch.mixins; + +import net.minecraft.client.renderer.EntityRenderer; +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; + +@Mixin(EntityRenderer.class) +public class MixinEntityRenderer { + + @Inject( + method = "renderWorldPass", + at = @At( + value = "INVOKE_STRING", + target = "Lnet/minecraft/profiler/Profiler;endStartSection(Ljava/lang/String;)V", args = { "ldc=hand" } + ) + ) + private void renderWorldPass(CallbackInfo ci) { + + } + + +}