Jump to content

GMqwerty

Members
  • Posts

    6
  • Joined

  • Last visited

Everything posted by GMqwerty

  1. yea ik, i just want to check what items players near me hold, i am making a mod that shows you if someone is going to attack you, so if someone is holding a sword and is in a 10 block radius it shows you a message
  2. I want to run some code when a player holds a sword, so I guess I would have to check constantly? i dont know tho
  3. I want to check all players on a server if they are holding a specific item. I think I understand how to get the item they are holding, but I dont know from which event to check?
  4. Oh alright thanks! EDIT: just tried it and it worked!
  5. oh so how can i draw text on top of the furnace GUI?
  6. @SubscribeEvent public void RenderGameOverlay(RenderGameOverlayEvent event) { Minecraft mc = Minecraft.getInstance(); PlayerEntity player = mc.player; FontRenderer fontRenderer = mc.font; if ( mc.screen instanceof FurnaceScreen) { if(event.getType() == RenderGameOverlayEvent.ElementType.TEXT) { fontRenderer.draw(event.getMatrixStack(), "lol", 175, 125, 0); } } } I want to draw text on the furnace gui and I have tested it and it works, but it draws behind the gui. How can I solve this issue?
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.