Posted January 12, 20214 yr i have tried to use this but it doesnt work public static final KeyBinding LMB = new KeyBinding("key.structure.left", GLFW.GLFW_MOUSE_BUTTON_LEFT, "key.hentai.category.left"); @SubscribeEvent (priority = EventPriority.LOWEST) public static void onClientTick(TickEvent.ClientTickEvent event) throws Exception { if(event.phase.equals(TickEvent.Phase.END)){ if(LMB.isKeyDown()) { System.out.println("Hello"); } } } Edited January 12, 20214 yr by Klarks
January 12, 20214 yr GameSettings.keyBindAttack. You can get the instance of game settings in Minecraft.
January 12, 20214 yr Author I already tried to get it from gamesetting but for some reason i cant Edited January 12, 20214 yr by Klarks
January 12, 20214 yr 11 minutes ago, poopoodice said: You can get the instance of game settings in Minecraft.
January 13, 20214 yr You can use one of the subclasses of net.minecraftforge.event.entity.player.PlayerInteractEvent, some of which are fired both client and server side. The javadoc comments for each of these classes tell you on which sides the event will be fired.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.