-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Breaks toggle sprint #7
Comments
I was trying to find the cause for this and it appears to be a conflict with RandomPatches! Either mod on its own is fine, just the combination is not. A temporary workaround is to set My guess is that it's this piece of code since everything else seems to be a NOP with default settings: And recompiling without it does indeed eliminate the conflict! I'm not sure however what part of Mouse Wheelie is conflicting. |
Oh, just noticed, I was talking about Toggle Sneak the whole time while the original issue was about Toggle Sprint, so that means it's not just shift but also control which is affected - which again matches |
It seems Turns out it's not about Mouse Wheelie, it's about amecs! |
Hm... looks like this is not fixed, I built mouse-wheelie from source, but the conflict with RandomPatches is still there. Comparing amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinKeyBinding.java Lines 121 to 124 in b5f72b1
with https://github.com/TheRandomLabs/RandomPatches/blob/291a49bf05ec37312680287202e5d6b65eeb1d73/src/main/java/com/therandomlabs/randompatches/mixin/client/keybindings/KeyBindingMixin.java#L108-L114 it looks like KeyBindingManager.setKeyPressed(keyCode, pressed); might not execute because of RandomPatches' info.cancel(); (depending on mixin load order).
|
Ok, I think the main thing is that Siphalor/amecs#31 is not actually related to this. (That issue is resolved now and therefore I also closed this one). I'm gonna see what I can do about the RandomPatches compat. |
Just added a |
Wild guess without looking at the code too much: Since both mods manually call |
That makes a lot of sense! It actually looks like amecs-api and RP are trying to do the exact same thing: executing every keybinding with the key that was just pressed. It should probably be RP which disables the mixin when amecs-api is present - the way it's done ( I wonder tough, since amecs-api does not cancel the vanilla call, doesn't that mean that one keybinding will execute twice? |
Hm... or does it make sense? |
amecs-api/src/main/java/de/siphalor/amecs/api/AmecsKeyBinding.java Lines 35 to 38 in b5f72b1
But I'm not sure how AmecsKeyBinding is used in the context of sneaking.
|
Aha, it looks like sprinting uses a |
Yea, that's what I feared. |
I think there's a really simple fix: adding an That'll ensure Only thing is that I'm not 100% sure if RP's and amces-api's code is equivalent. |
The code is not equivalent as Amecs handles a bunch of other things concerning the modifiers in that method as well. Yea, you're right that should probably be in RP. |
In that case, it definitively needs to be in RP, because when the mixin load order is different, amecs-api's code won't execute at all. I'd write a PR, but I'm currently having a lot of trouble with gradle and IDEA, building RP randomly starts failing, the project won't open with the message |
Just a small status update: This issue and the associated one at Random Patches are waiting for the pull request in Random Patches to get approved and merged. |
Current Status: #7 (comment)
Version
1.16.5, 1.6.4
Describe the bug
When using the mod, the Minecraft toggle sprint doesn't work
To Reproduce
Expected behavior
Toggle sprint should work fine
Log
There aren't really any logs for this
Additional context
Modpack: https://www.curseforge.com/minecraft/modpacks/simpearth/files/3209728
The text was updated successfully, but these errors were encountered: