Posted July 1, 20169 yr PlayerInteractEvent.RightClickItem says in the forge file: /** * This event is fired on both sides before the player triggers {@link net.minecraft.item.Item#onItemRightClick}. * Note that this is NOT fired if the player is targeting a block. For that case, see {@link RightClickBlock}. **/ However, when I use that event to open a gui and PlayerInteractEvent.RightClickBlock, it gets called and the gui opens even if i am looking at a block. Anybody now why this is or how to fix it?
July 1, 20169 yr Author Thanks! I'm checking with a RayTraceResult if the player is looking at a block. The Forge Description for this method is a bit confusing... Oh well. Thank you again!
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.