Skip to content

Commit bc3cc30

Browse files
committed
fix mixin class names and move remap = false to the annotation
1 parent dc423ea commit bc3cc30

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

src/main/java/com/lambda/mixin/baritone/MixinBaritonePlayerContext.java renamed to src/main/java/com/lambda/mixin/baritone/BaritonePlayerContextMixin.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable;
3131

3232
@Mixin(value = BaritonePlayerContext.class, remap = false) // fix compileJava warning
33-
public class MixinBaritonePlayerContext {
33+
public class BaritonePlayerContextMixin {
3434
@Shadow
3535
@Final
3636
private Baritone baritone;

src/main/java/com/lambda/mixin/baritone/MixinLookBehavior.java renamed to src/main/java/com/lambda/mixin/baritone/LookBehaviourMixin.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@
2828
import org.spongepowered.asm.mixin.injection.Inject;
2929
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
3030

31-
@Mixin(LookBehavior.class)
32-
public class MixinLookBehavior {
31+
@Mixin(value = LookBehavior.class, remap = false)
32+
public class LookBehaviourMixin {
3333
// Redirect baritone's rotations into our rotation engine
34-
@Inject(method = "updateTarget", at = @At("HEAD"), remap = false, cancellable = true)
34+
@Inject(method = "updateTarget", at = @At("HEAD"), cancellable = true)
3535
void onTargetUpdate(Rotation rotation, boolean blockInteract, CallbackInfo ci) {
3636
LookBehavior instance = ((LookBehavior) (Object) this);
3737
if (instance.baritone != BaritoneManager.getPrimary()) return;
@@ -40,15 +40,15 @@ void onTargetUpdate(Rotation rotation, boolean blockInteract, CallbackInfo ci) {
4040
ci.cancel();
4141
}
4242

43-
@Inject(method = "onPlayerUpdate", at = @At("HEAD"), remap = false, cancellable = true)
43+
@Inject(method = "onPlayerUpdate", at = @At("HEAD"), cancellable = true)
4444
void onUpdate(PlayerUpdateEvent event, CallbackInfo ci) {
4545
LookBehavior instance = ((LookBehavior) (Object) this);
4646
if (instance.baritone != BaritoneManager.getPrimary()) return;
4747

4848
ci.cancel();
4949
}
5050

51-
@Inject(method = "onPlayerRotationMove", at = @At("HEAD"), remap = false, cancellable = true)
51+
@Inject(method = "onPlayerRotationMove", at = @At("HEAD"), cancellable = true)
5252
void onMovementUpdate(RotationMoveEvent event, CallbackInfo ci) {
5353
LookBehavior instance = ((LookBehavior) (Object) this);
5454
if (instance.baritone != BaritoneManager.getPrimary()) return;

src/main/resources/lambda.mixins.common.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
"client": [
77
"CrashReportMixin",
88
"MinecraftClientMixin",
9-
"baritone.MixinBaritonePlayerContext",
10-
"baritone.MixinLookBehavior",
9+
"baritone.BaritonePlayerContextMixin",
10+
"baritone.LookBehaviourMixin",
1111
"client.sound.SoundSystemMixin",
1212
"entity.ClientPlayerEntityMixin",
1313
"entity.ClientPlayInteractionManagerMixin",

0 commit comments

Comments
 (0)