diff options
Diffstat (limited to 'src/main/java/moe/nea/firmament/mixins/ToggleSprintPatch.java')
| -rw-r--r-- | src/main/java/moe/nea/firmament/mixins/ToggleSprintPatch.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/moe/nea/firmament/mixins/ToggleSprintPatch.java b/src/main/java/moe/nea/firmament/mixins/ToggleSprintPatch.java index 1acbf20..96d03bd 100644 --- a/src/main/java/moe/nea/firmament/mixins/ToggleSprintPatch.java +++ b/src/main/java/moe/nea/firmament/mixins/ToggleSprintPatch.java @@ -3,16 +3,16 @@ package moe.nea.firmament.mixins; import moe.nea.firmament.features.fixes.Fixes; -import net.minecraft.client.option.KeyBinding; +import net.minecraft.client.KeyMapping; 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.CallbackInfoReturnable; -@Mixin(KeyBinding.class) +@Mixin(KeyMapping.class) public class ToggleSprintPatch { - @Inject(method = "isPressed", at = @At("HEAD"), cancellable = true) + @Inject(method = "isDown", at = @At("HEAD"), cancellable = true) public void onIsPressed(CallbackInfoReturnable<Boolean> cir) { - Fixes.INSTANCE.handleIsPressed((KeyBinding) (Object) this, cir); + Fixes.INSTANCE.handleIsPressed((KeyMapping) (Object) this, cir); } } |
