Problem with an overlay

Started by Sushiue on

Topic category: Help with MCreator software

Last seen on 14:32, 26. Apr 2024
Joined Feb 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Problem with an overlay

I recently made that with a item every cobblestone that is in the player inventory is removed ands adds a +1 to a global variable. Then i wanted when right clicked with the item to show the overlay where it would show how many cobblestone you have, and it worked great  ! But only when i right clicked in the air, when i do the same procedure for right clicking on a block it just don't works and i can't figure out why. Nothing change there is the sound and particules but it doesn't change the variable to false or true for the overlay.

The procedure that i use for right click to make the overlay true or false :

i use the same procedure for both of the case :

but the only one that works is for right clicking in the air please help !