
[1.21.1] Punching air doesn't do anything
ascenstohe4vn opened this issue ยท 4 comments
I'm also experiencing this issue. For me, it appears that all books are affected, but a specific tested example would be the guide book from Modern Industrialization.
I'm running the game with many other mods installed; here is a complete modlist: https://gist.github.com/unilock/bffcfe138d617f1a187d76f93278e2b4
It's likely this is a mod conflict of some sort.
Unfortunately, there doesn't appear to be any helpful information in the logs regarding this issue.
My slightly hacky fix was to add a listener to InputEvent.InteractionKeyMappingTriggered
that calls MorphingHandler#onPlayerLeftClick
if the conditions are met for an "empty left click":
NeoForge.EVENT_BUS.addListener(InputEvent.InteractionKeyMappingTriggered.class, event -> {
if (event.isAttack() && Minecraft.getInstance().hitResult != null && Minecraft.getInstance().hitResult.getType() == HitResult.Type.MISS) {
MorphingHandler.INSTANCE.onPlayerLeftClick(new PlayerInteractEvent.LeftClickEmpty(Minecraft.getInstance().player));
}
});
I guess some other mod is cancelling either this event, or PlayerInteractEvent.LeftClickEmpty
.