how do i render an overlay only when i pull out a specific item?

Started by RishonRJ on

Topic category: Help with Minecraft modding (Java Edition)

Joined Apr 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
how do i render an overlay only when i pull out a specific item?

how do i render an overlay only when i pull out a specific item? i have been trying to make a procedure to render only if my custom item is in the main hand. how do i do this?

Joined Jul 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
There's a box in the overlay…
Sun, 05/29/2022 - 06:47

There's a box in the overlay editor called "Display overlay in-game" which wants a procedure that returns a boolean. If the procedure returns true, the overlay is displayed and vice versa...

In the procedure, you could check the item in player's main hand if it's equal to your specific item. If true, then return true.

 

Image: https://imgur.com/RdCwo2V